Fix display of task error

This commit is contained in:
Girish Ramakrishnan
2022-02-01 21:47:49 -08:00
parent 67fe17d20c
commit 26bfa32c7b

View File

@@ -178,7 +178,7 @@ function startTask(id, options, callback) {
const [getError, task] = await safe(get(id));
let taskError;
let taskError = null;
if (!getError && task.percent !== 100) { // taskworker crashed or was killed by us
if (code === 0) {
taskError = {
@@ -204,7 +204,7 @@ function startTask(id, options, callback) {
if (callback) callback(taskError, task ? task.result : null);
debug(`startTask: ${id} done. error: `, taskError);
debug(`startTask: ${id} done. error: ${taskError}`);
});
if (options.timeout) {