From 69fe6256fac30de250357570d8b1acd8cd39a8d3 Mon Sep 17 00:00:00 2001 From: Hiroyuki Date: Sun, 12 Sep 2021 22:07:12 -0400 Subject: [PATCH] fix: usermod account unlock logic --- src/commands/usermod.ts | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/commands/usermod.ts b/src/commands/usermod.ts index d8e6c0d..510be81 100644 --- a/src/commands/usermod.ts +++ b/src/commands/usermod.ts @@ -65,10 +65,8 @@ export default class Usermod extends Command { await this.client.util.handleError(error); return this.error(message.channel, 'Failed to modify username. Please check <#595788220764127272> for more information.'); } finally { - if (account.locked) { - await this.client.util.exec(`unlock ${account.username}`); - await account.updateOne({ locked: false }); - } + await this.client.util.exec(`unlock ${account.username}`); + await account.updateOne({ locked: false }); } modifyingPropertyResponse.delete();