mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-03 20:45:58 +01:00
closes #5845
This commit is contained in:
@@ -65,7 +65,7 @@
|
||||
"nodebb-plugin-spam-be-gone": "0.5.0",
|
||||
"nodebb-rewards-essentials": "0.0.9",
|
||||
"nodebb-theme-lavender": "4.0.5",
|
||||
"nodebb-theme-persona": "5.0.16",
|
||||
"nodebb-theme-persona": "5.0.18",
|
||||
"nodebb-theme-slick": "1.1.0",
|
||||
"nodebb-theme-vanilla": "6.0.13",
|
||||
"nodebb-widget-essentials": "3.0.1",
|
||||
|
||||
@@ -88,11 +88,6 @@ User.getUsersWithFields = function (uids, fields, uid, callback) {
|
||||
user.banned = parseInt(user.banned, 10) === 1;
|
||||
}
|
||||
|
||||
if (user.hasOwnProperty('banned:expire')) {
|
||||
user.banned_until = parseInt(user['banned:expire'], 10) || 0;
|
||||
user.banned_until_readable = user.banned_until ? new Date(user.banned_until).toString() : 'Not Banned';
|
||||
}
|
||||
|
||||
if (user.hasOwnProperty(['email:confirmed'])) {
|
||||
user['email:confirmed'] = parseInt(user['email:confirmed'], 10) === 1;
|
||||
}
|
||||
|
||||
@@ -168,6 +168,11 @@ module.exports = function (User) {
|
||||
if (user.hasOwnProperty('lastonline')) {
|
||||
user.lastonlineISO = utils.toISOString(user.lastonline) || user.joindateISO;
|
||||
}
|
||||
|
||||
if (user.hasOwnProperty('banned:expire')) {
|
||||
user.banned_until = parseInt(user['banned:expire'], 10) || 0;
|
||||
user.banned_until_readable = user.banned_until ? new Date(user.banned_until).toString() : 'Not Banned';
|
||||
}
|
||||
});
|
||||
|
||||
plugins.fireHook('filter:users.get', users, callback);
|
||||
|
||||
Reference in New Issue
Block a user