Remove fallback changes
This commit is contained in:
parent
41541c2ffd
commit
bfe2e5b76b
@ -30,11 +30,7 @@ MainFallback.prototype.getNextQuery = function (job) {
|
|||||||
|
|
||||||
MainFallback.prototype.getOnSuccess = function (job) {
|
MainFallback.prototype.getOnSuccess = function (job) {
|
||||||
if (job.status === jobStatus.DONE && job.fallback_status === jobStatus.PENDING) {
|
if (job.status === jobStatus.DONE && job.fallback_status === jobStatus.PENDING) {
|
||||||
var onsuccessQuery = job.query.onsuccess;
|
return job.query.onsuccess;
|
||||||
if (onsuccessQuery) {
|
|
||||||
onsuccessQuery = onsuccessQuery.replace(/<%=\s*job_id\s*%>/g, job.job_id);
|
|
||||||
}
|
|
||||||
return onsuccessQuery;
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -44,12 +40,7 @@ MainFallback.prototype.hasOnSuccess = function (job) {
|
|||||||
|
|
||||||
MainFallback.prototype.getOnError = function (job) {
|
MainFallback.prototype.getOnError = function (job) {
|
||||||
if (job.status === jobStatus.FAILED && job.fallback_status === jobStatus.PENDING) {
|
if (job.status === jobStatus.FAILED && job.fallback_status === jobStatus.PENDING) {
|
||||||
var onerrorQuery = job.query.onerror;
|
return job.query.onerror;
|
||||||
if (onerrorQuery) {
|
|
||||||
onerrorQuery = onerrorQuery.replace(/<%=\s*job_id\s*%>/g, job.job_id);
|
|
||||||
onerrorQuery = onerrorQuery.replace(/<%=\s*error_message\s*%>/g, job.failed_reason);
|
|
||||||
}
|
|
||||||
return onerrorQuery;
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user