mirror of
https://github.com/NodeBB/NodeBB.git
synced 2026-01-04 14:50:47 +01:00
more refactors
This commit is contained in:
@@ -37,13 +37,13 @@ module.exports = function(SocketPosts) {
|
||||
function (results, next) {
|
||||
async.parallel({
|
||||
upvoters: function(next) {
|
||||
user.getMultipleUserFields(results.upvoteUids, ['username', 'userslug', 'picture'], next);
|
||||
user.getUsersFields(results.upvoteUids, ['username', 'userslug', 'picture'], next);
|
||||
},
|
||||
upvoteCount: function(next) {
|
||||
next(null, results.upvoteUids.length);
|
||||
},
|
||||
downvoters: function(next) {
|
||||
user.getMultipleUserFields(results.downvoteUids, ['username', 'userslug', 'picture'], next);
|
||||
user.getUsersFields(results.downvoteUids, ['username', 'userslug', 'picture'], next);
|
||||
},
|
||||
downvoteCount: function(next) {
|
||||
next(null, results.downvoteUids.length);
|
||||
|
||||
Reference in New Issue
Block a user