Let unhandled rejection handler handle rejections in jobs

This commit is contained in:
Akihiko Odaki
2018-04-05 01:04:44 +09:00
parent d7c13b975f
commit e330ac1934
9 changed files with 134 additions and 111 deletions

View File

@@ -14,4 +14,4 @@ const handlers = {
unfollow
};
export default (job, done) => handlers[job.data.type](job).then(() => done(), done);
export default (job, done) => handlers[job.data.type](job, done);