schedulerConfig cannot be null

This commit is contained in:
Girish Ramakrishnan
2015-10-20 09:44:46 -07:00
parent 5ae4c891de
commit 3fd9d9622b

View File

@@ -121,9 +121,10 @@ function stopJobs(appId, appState, callback) {
}
function createCronJobs(appId, schedulerConfig) {
debug('creating cron jobs for app %s', appId);
assert.strictEqual(typeof appId, 'string');
assert(schedulerConfig && typeof schedulerConfig === 'object');
if (!schedulerConfig) return null;
debug('creating cron jobs for app %s', appId);
var jobs = { };