From dabfa8d8d2e9b9c28d5cea262fbf918f2a4071ab Mon Sep 17 00:00:00 2001 From: Erik <33332790+Navy-gif@users.noreply.github.com> Date: Tue, 26 Jul 2022 01:03:12 +0300 Subject: [PATCH] bugfix --- src/localization/en_gb/settings/en_gb_moderation.lang | 3 +++ src/structure/components/settings/moderation/WordFilter.js | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/localization/en_gb/settings/en_gb_moderation.lang b/src/localization/en_gb/settings/en_gb_moderation.lang index bb5b748..1f516fd 100644 --- a/src/localization/en_gb/settings/en_gb_moderation.lang +++ b/src/localization/en_gb/settings/en_gb_moderation.lang @@ -350,6 +350,9 @@ __Letting this prompt time out will make the action a **generic** one.__ The following words are already tied to an action and were skipped. `{words}` +[SETTING_WORDFILTER_INVALID] +No valid values supplied. + // Linkfilter [SETTING_LINKFILTER_HELP] Configure the link filtering behaviour for your server. diff --git a/src/structure/components/settings/moderation/WordFilter.js b/src/structure/components/settings/moderation/WordFilter.js index 78df6e5..5ba066c 100644 --- a/src/structure/components/settings/moderation/WordFilter.js +++ b/src/structure/components/settings/moderation/WordFilter.js @@ -147,7 +147,7 @@ class WordFilterSetting extends FilterSetting { if (!params.length) { if (['roles', 'channels'].includes(list.value)) return { error: true, index: 'RESOLVE_FAIL', params: { type: list === 'bypass' ? 'roles' : 'channels' } }; - return { error: true, index }; + return { error: true, index: 'SETTING_WORDFILTER_INVALID' }; } const { modified } = this[method](setting[list], params.map((o) => o.id || o)); return { index, params: { updated: list, modified: params.filter((o) => modified.includes(o.id || o)).map((o) => o.name || o).join('__, __'), invalid: invalid.join('`, `') } };