diff --git a/package-lock.json b/package-lock.json index f29f13a..bed8a94 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "@greencoast/discord.js-extended", - "version": "2.2.1", + "version": "2.2.2", "lockfileVersion": 2, "requires": true, "packages": { diff --git a/package.json b/package.json index 33848af..1e0dde3 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@greencoast/discord.js-extended", - "version": "2.2.1", + "version": "2.2.2", "description": "An utility to facilitate the repetitive tasks when creating discord bots. Used by Greencoast Studios.", "main": "./dist/index.js", "types": "./dist/index.d.ts", diff --git a/src/classes/locale/Localizer.ts b/src/classes/locale/Localizer.ts index e31ec1e..0c6cede 100644 --- a/src/classes/locale/Localizer.ts +++ b/src/classes/locale/Localizer.ts @@ -139,7 +139,11 @@ class Localizer { return Promise.resolve(); } - return this.client.dataProvider.delete(guild, this.options.dataProviderKey || 'locale'); + return this.client.dataProvider.delete(guild, this.options.dataProviderKey || 'locale') + .catch((error) => { + this.client.emit('warn', `Could not delete locale settings for ${guild.id} from data provider.`); + this.client.emit('error', error); + }); } /**