Use isStaff instead

This commit is contained in:
Chi Vinh Le
2017-11-01 13:29:04 +01:00
parent cee68ae471
commit ce0b63fe75
+1 -1
View File
@@ -35,7 +35,7 @@ const createAction = async ({user = {}, pubsub, loaders: {Comments}}, {item_id,
// Set the user as pending if it was a user flag and user has no Admin, Staff or Moderation roles
let user = await UsersService.findById(item_id);
if(!user.roles){
if(!user.isStaff()){
await UsersService.setStatus(item_id, 'PENDING');
}
}