mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-01 03:26:04 +01:00
Use async v2
This commit is contained in:
@@ -8,12 +8,8 @@ var helpers = {};
|
||||
|
||||
helpers.some = function (tasks, callback) {
|
||||
async.some(tasks, function (task, next) {
|
||||
task(function (err, result) {
|
||||
next(!err && result);
|
||||
});
|
||||
}, function (result) {
|
||||
callback(null, result);
|
||||
});
|
||||
task(next);
|
||||
}, callback);
|
||||
};
|
||||
|
||||
helpers.isUserAllowedTo = function (privilege, uid, cid, callback) {
|
||||
|
||||
Reference in New Issue
Block a user