oops
This commit is contained in:
parent
b5a74bd241
commit
21ebc5e84e
1 changed files with 1 additions and 1 deletions
|
@ -49,7 +49,7 @@ module.exports = async (params, user, _, isSecure) => new Promise(async (res, re
|
||||||
// Get 'is_bot' parameter
|
// Get 'is_bot' parameter
|
||||||
const [isBot, isBotErr] = $(params.is_bot).optional.boolean().$;
|
const [isBot, isBotErr] = $(params.is_bot).optional.boolean().$;
|
||||||
if (isBotErr) return rej('invalid is_bot param');
|
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, {
|
await User.update(user._id, {
|
||||||
$set: {
|
$set: {
|
||||||
|
|
Loading…
Reference in a new issue