mirror of
https://github.com/balena-os/balena-supervisor.git
synced 2025-02-20 17:52:51 +00:00
Always add status to image download report
It seems that in some cases the supervisor can report an image without a `status` field leading to a cloud side 401 response. See #1905 for more details. Change-type: patch
This commit is contained in:
parent
37a82e2dd6
commit
21c1c006f7
@ -193,7 +193,11 @@ export async function triggerFetch(
|
||||
}
|
||||
|
||||
const onProgress = (progress: FetchProgressEvent) => {
|
||||
reportEvent('update', { ...image, downloadProgress: progress.percentage });
|
||||
reportEvent('update', {
|
||||
...image,
|
||||
downloadProgress: progress.percentage,
|
||||
status: 'Downloading',
|
||||
});
|
||||
};
|
||||
|
||||
let success: boolean;
|
||||
@ -261,7 +265,7 @@ export async function triggerFetch(
|
||||
}
|
||||
}
|
||||
|
||||
reportEvent('finish', image);
|
||||
reportEvent('finish', { ...image, status: 'Downloaded' });
|
||||
onFinish(success);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user