diff --git a/stores/user.js b/stores/user.js index 3e264a9..3a52f01 100644 --- a/stores/user.js +++ b/stores/user.js @@ -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 })