Fix !chown
TypeError: fn.bind is not a function at Map.find (/app/node_modules/discord.js/src/util/Collection.js:171:49) at Object.exec (/app/src/mppbridger.js:465:46) at <anonymous> at process._tickCallback (internal/process/next_tick.js:188:7)
This commit is contained in:
parent
d9f1ab5e09
commit
13ebc32b20
|
@ -462,7 +462,7 @@ commands.chown = {
|
|||
MANAGE_WEBHOOKS: true,
|
||||
MANAGE_MESSAGES: true
|
||||
});
|
||||
let po = msg.channel.permissionOverwrites.find('id', msg.author.id);
|
||||
let po = msg.channel.permissionOverwrites.find(x => x.id == msg.author.id);
|
||||
if (po) po.delete();
|
||||
await dbClient.query('UPDATE bridges SET owner_discord_user_id = $1 WHERE discord_channel_id = $2;', [selectedUser.id, msg.channel.id]);
|
||||
msg.channel.send(`Ownership of ${msg.channel} has been transferred to ${selectedUser}`);
|
||||
|
|
Loading…
Reference in New Issue