diff --git a/options.json b/options.json index 1ca8ac1..2712c35 100644 --- a/options.json +++ b/options.json @@ -3,7 +3,9 @@ "shardOptions": { "totalShards": "auto", "respawn": true, - "execArgv": ["--enable-source-maps"] + "execArgv": [ + "--enable-source-maps" + ] }, "discord": { "prefix": "!", diff --git a/src/client/components/settings/moderation/Mute.ts b/src/client/components/settings/moderation/Mute.ts index f774480..0f9aa6f 100644 --- a/src/client/components/settings/moderation/Mute.ts +++ b/src/client/components/settings/moderation/Mute.ts @@ -304,7 +304,9 @@ class MuteSetting extends Setting return { index: 'SETTING_MUTE_ABORT', error: true }; } else + { invoker.editReply({ content: 'Working...', emoji: 'working' }); + } if (!role) { @@ -358,7 +360,11 @@ class MuteSetting extends Setting } catch (err) { - this.client.logger.error(err as Error); + const error = err as Error; + if (error.message === 'Missing Permissions') + issues.push({ type: 'permission', channel: channel.name, permissions: [ 'unknown' ] }); + else + this.client.logger.error('Error during mute role create while creating channel overrides\n', error); } } diff --git a/src/client/infractions/Mute.ts b/src/client/infractions/Mute.ts index 0eea6ef..213df6b 100644 --- a/src/client/infractions/Mute.ts +++ b/src/client/infractions/Mute.ts @@ -127,8 +127,10 @@ class MuteInfraction extends Infraction catch (e) { const err = e as Error; + if (err.message.includes('Missing Permissions')) + return this._fail('COMMAND_MUTE_4FAIL'); this.logger.error(`Mute timeout failed:\n${err.stack || err}`); - return this._fail('COMMAND_MUTE_4FAIL'); + return this._fail('ERR_INTERNAL'); } } diff --git a/src/localization/en_gb/commands/en_gb_information.lang b/src/localization/en_gb/commands/en_gb_information.lang index 770a1d8..6bbca04 100644 --- a/src/localization/en_gb/commands/en_gb_information.lang +++ b/src/localization/en_gb/commands/en_gb_information.lang @@ -39,7 +39,7 @@ For a list of all available commands, use `/commands [ group ]`. Conflicting names can be prefixed with the component type to specify, e.g. `command:permissions` and `setting:permissions`. **❯ Links** -[Documentation](https://galactic.corgi.wtf/documentation) +[Documentation](https://galactic.corgi.wtf/docs) [Dashboard](https://galactic.corgi.wtf/dashboard) **[NON-FUNCTIONAL PRE-ALPHA]** [Support & Info server](https://discord.gg/SvJgtEj) [@BotGalactic Twitter](https://twitter.com/BotGalactic) diff --git a/src/localization/en_gb/general/en_gb_errors.lang b/src/localization/en_gb/general/en_gb_errors.lang index 87d031b..5d5bff3 100644 --- a/src/localization/en_gb/general/en_gb_errors.lang +++ b/src/localization/en_gb/general/en_gb_errors.lang @@ -36,4 +36,7 @@ The user's role is above the bot's. Invalid channel type [ERR_NOT_IMPLEMENTED] -This functionality is not implemented yet \ No newline at end of file +This functionality is not implemented yet + +[ERR_INTERNAL] +Internal error \ No newline at end of file