|
|
|
@ -2,15 +2,13 @@
|
|
|
|
|
|
|
|
|
|
'use strict';
|
|
|
|
|
|
|
|
|
|
var async = require('async'),
|
|
|
|
|
db = require('./database'),
|
|
|
|
|
utils = require('../public/src/utils');
|
|
|
|
|
var async = require('async');
|
|
|
|
|
var db = require('./database');
|
|
|
|
|
var utils = require('../public/src/utils');
|
|
|
|
|
|
|
|
|
|
(function (Batch) {
|
|
|
|
|
var DEFAULT_BATCH_SIZE = 100;
|
|
|
|
|
|
|
|
|
|
var DEFAULT_BATCH_SIZE = 100;
|
|
|
|
|
|
|
|
|
|
Batch.processSortedSet = function (setKey, process, options, callback) {
|
|
|
|
|
exports.processSortedSet = function (setKey, process, options, callback) {
|
|
|
|
|
if (typeof options === 'function') {
|
|
|
|
|
callback = options;
|
|
|
|
|
options = {};
|
|
|
|
@ -61,9 +59,9 @@ var async = require('async'),
|
|
|
|
|
},
|
|
|
|
|
callback
|
|
|
|
|
);
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
Batch.processArray = function (array, process, options, callback) {
|
|
|
|
|
exports.processArray = function (array, process, options, callback) {
|
|
|
|
|
if (typeof options === 'function') {
|
|
|
|
|
callback = options;
|
|
|
|
|
options = {};
|
|
|
|
@ -109,6 +107,4 @@ var async = require('async'),
|
|
|
|
|
callback(err);
|
|
|
|
|
}
|
|
|
|
|
);
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
}(exports));
|
|
|
|
|
};
|
|
|
|
|