|
|
@ -261,13 +261,13 @@ var nt = nThen(function (w) {
|
|
|
|
config.store = _store;
|
|
|
|
config.store = _store;
|
|
|
|
}));
|
|
|
|
}));
|
|
|
|
}).nThen(function (w) {
|
|
|
|
}).nThen(function (w) {
|
|
|
|
if (!config.enableTaskScheduling) { return; }
|
|
|
|
|
|
|
|
var Tasks = require("./storage/tasks");
|
|
|
|
var Tasks = require("./storage/tasks");
|
|
|
|
Tasks.create(config, w(function (e, tasks) {
|
|
|
|
Tasks.create(config, w(function (e, tasks) {
|
|
|
|
if (e) {
|
|
|
|
if (e) {
|
|
|
|
throw e;
|
|
|
|
throw e;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
config.tasks = tasks;
|
|
|
|
config.tasks = tasks;
|
|
|
|
|
|
|
|
if (config.disableIntegratedTasks) { return; }
|
|
|
|
setInterval(function () {
|
|
|
|
setInterval(function () {
|
|
|
|
tasks.runAll(function (err) {
|
|
|
|
tasks.runAll(function (err) {
|
|
|
|
if (err) {
|
|
|
|
if (err) {
|
|
|
|