3
0
Fork 0
mirror of https://github.com/ZeppelinBot/Zeppelin.git synced 2025-03-15 05:41:51 +00:00

Tweak counter reset logic (v2)

This commit is contained in:
Dragory 2021-05-03 20:45:33 +03:00
parent 7fc86d34e9
commit 724abc89b9
No known key found for this signature in database
GPG key ID: 5F387BA66DF8AAC1

View file

@ -50,8 +50,10 @@ export const ResetAllCounterValuesCmd = guildCommand<CountersPluginType>()({
const lock = await pluginData.locks.acquire(counterIdLock(counterId)); const lock = await pluginData.locks.acquire(counterIdLock(counterId));
await resetAllCounterValues(pluginData, args.counterName); await resetAllCounterValues(pluginData, args.counterName);
lock.unlock(); lock.interrupt();
sendSuccessMessage(pluginData, message.channel, `All counter values for **${counterName}** have been reset`); sendSuccessMessage(pluginData, message.channel, `All counter values for **${counterName}** have been reset`);
pluginData.getKnubInstance().reloadGuild(pluginData.guild.id);
}, },
}); });