diff --git a/src/commands.js b/src/commands.js index 75b36ba..8bcc3b6 100755 --- a/src/commands.js +++ b/src/commands.js @@ -80,6 +80,7 @@ global.commands = { } if (!channel.permissionsFor(msg.member).has('MANAGE_CHANNELS')) return msg.react('🚫'); await channel.setParent(config.channels.deleted_channels); + await new Promise(resolve => setTimeout(resolve, 500)); await channel.lockPermissions(); msg.react('🆗'); } diff --git a/src/mppbridger/commands/bridge.js b/src/mppbridger/commands/bridge.js index 66b32f7..d6da392 100644 --- a/src/mppbridger/commands/bridge.js +++ b/src/mppbridger/commands/bridge.js @@ -16,6 +16,7 @@ module.exports = { let channel = dClient.guilds.get(config.guildID).channels.get(existingBridge.discord_channel_id); await dbClient.query("UPDATE bridges SET disabled = false WHERE mpp_room = $1", [room]); await channel.setParent(config.channels.mpp_bridges); + await new Promise(resolve => setTimeout(resolve, 500)); await channel.lockPermissions(); let existingClient = clients.MPP[room]; if (existingClient) existingClient.start(); diff --git a/src/mppbridger/commands/unbridge.js b/src/mppbridger/commands/unbridge.js index dbb2a30..74d6661 100644 --- a/src/mppbridger/commands/unbridge.js +++ b/src/mppbridger/commands/unbridge.js @@ -22,6 +22,7 @@ module.exports = { if (client) client.stop(); var channel = dClient.channels.get(bridge.discord_channel_id) await channel.setParent(config.channels.deleted_bridges); + await new Promise(resolve => setTimeout(resolve, 500)); await channel.lockPermissions(); msg.reply(`${bridge.mpp_room} has been unbridged.`); }