Skip to content

Commit

Permalink
Make sure error is always passed to callback
Browse files Browse the repository at this point in the history
  • Loading branch information
Vladimir Protasov committed Aug 21, 2019
1 parent a85629c commit 0a485a7
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions rq_dashboard/templates/rq_dashboard/dashboard.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ var api = {
var instances = data.rq_instances;
cb(instances);
}).fail(function(err){
cb(null, err);
cb(null, err || true);
});
},

Expand All @@ -35,7 +35,7 @@ var api = {
var queues = data.queues;
cb(queues);
}).fail(function(err){
cb(null, err);
cb(null, err || true);
});
},

Expand All @@ -45,7 +45,7 @@ var api = {
var pagination = data.pagination;
cb(jobs, pagination);
}).fail(function(err){
cb(null, null, err);
cb(null, null, err || true);
});
},

Expand All @@ -54,7 +54,7 @@ var api = {
var workers = data.workers;
cb(workers);
}).fail(function(err){
cb(null, err);
cb(null, err || true);
});
}
};
Expand Down

0 comments on commit 0a485a7

Please sign in to comment.