2
0
mirror of https://github.com/thedevs-network/the-guard-bot synced 2025-08-29 13:17:56 +00:00

Keep warns in /unban

This commit is contained in:
GingerPlusPlus 2019-06-20 11:58:19 +02:00
parent 93ff9a7225
commit 0ea1e0064e

View File

@ -130,7 +130,7 @@ const unban = ({ id }) =>
User.update(
{ id },
{
$set: { status: 'member', warns: [] },
$set: { status: 'member' },
$unset: { ban_details: true, ban_reason: true },
}
);
@ -156,7 +156,7 @@ const unwarn = ({ id }, warnQuery) =>
}
);
const nowarns = unban;
const nowarns = query => unwarn(query, {});
const getWarns = ({ id }) =>
User.findOne({ id })