agenda
agenda copied to clipboard
Fixed this={} in processDbResult
trafficstars
this in processDbResult in save-job.js file is always {}, but it should be bound to agenda instance. Because of this a job is never run immediately, which is not a big issue, but it raises an error, for example, after Babel transpilation, because this is undefined.
Fixing it breaks the tests, because
processJobs.call(this, job);
might actually run and it doesn't take _jobsToLock into consideration. This is why a check for this was added.
Could this be reviewed , need this fix
rebased onto latest master