embark-area-51/lib/utils/async_extend.js

15 lines
284 B
JavaScript
Raw Normal View History

2017-03-11 15:52:02 +00:00
var async = require('async');
function asyncEachObject(object, iterator, callback) {
async.each(
Object.keys(object || {}),
function(key, next){
iterator(key, object[key], next);
},
callback
);
}
async.eachObject = asyncEachObject;
module.exports = async;