fix(v1/crawl-status): handle job's returnvalue being explicitly null (db race)
This commit is contained in:
@@ -157,10 +157,10 @@ export async function crawlStatusController(
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (job.returnvalue === undefined) {
|
if (job.returnvalue === undefined || job.returnvalue === null) {
|
||||||
logger.warn(
|
logger.warn(
|
||||||
"Job was considered done, but returnvalue is undefined!",
|
"Job was considered done, but returnvalue is undefined!",
|
||||||
{ jobId: job.id, state },
|
{ jobId: job.id, state, returnvalue: job.returnvalue },
|
||||||
);
|
);
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user