Fixed race condition where job would remain in delayed after failure

See https://github.com/LearnBoost/kue/issues/483