Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
if (currentlyExecutingTask) {
if (currentlyExecutingTask._depTask !== task) {
// this task is unperformable and is not a dependency
// of the currently running task, so we error.
return didNotRun();
} else {
// this task is unperformable, but that is because
// the currently running task (which specifies this task
// as a dependency) marked it as such. it is actually performable.
}
} else {
return didNotRun();
}
}
let proc = Process.create({
owner: task._hostObject,
generatorFunction: task._genFn,
propertyName: "TODO",
_task: task,
});
task._proc = proc;
this._incrementSemaphoresForTaskChain(task, +1);
return new Ember.RSVP.Promise(r => {
proc.start(args, returnValue => {
this._taskDidFinish(task);
r(returnValue);
});
});
},