summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/api/endpoints/i/update.ts2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/api/endpoints/i/update.ts b/src/api/endpoints/i/update.ts
index fc12665ad6..2a5dce64a8 100644
--- a/src/api/endpoints/i/update.ts
+++ b/src/api/endpoints/i/update.ts
@@ -49,7 +49,7 @@ module.exports = async (params, user, _, isSecure) => new Promise(async (res, re
// Get 'is_bot' parameter
const [isBot, isBotErr] = $(params.is_bot).optional.boolean().$;
if (isBotErr) return rej('invalid is_bot param');
- if (isBot) user.is_bot = isBot;
+ if (isBot != null) user.is_bot = isBot;
await User.update(user._id, {
$set: {