diff --git a/src/compose/application-manager.ts b/src/compose/application-manager.ts index 920bed29..0cc00e0c 100644 --- a/src/compose/application-manager.ts +++ b/src/compose/application-manager.ts @@ -1041,7 +1041,9 @@ export async function getState() { commit, serviceName, status: status as string, - ...(downloadProgress && { download_progress: downloadProgress }), + ...(Number.isInteger(downloadProgress) && { + download_progress: downloadProgress, + }), }), ); diff --git a/test/src/compose/application-manager.spec.ts b/test/src/compose/application-manager.spec.ts index 79bc6441..015f7703 100644 --- a/test/src/compose/application-manager.spec.ts +++ b/test/src/compose/application-manager.spec.ts @@ -1373,6 +1373,14 @@ describe('compose/application-manager', () => { serviceName: 'ubuntu', status: 'Downloaded', }, + { + name: 'node:latest', + commit: 'latestrelease', + appUuid: 'myapp', + serviceName: 'node', + status: 'Downloading', + downloadProgress: 0, + }, { name: 'alpine:latest', commit: 'latestrelease', @@ -1427,6 +1435,11 @@ describe('compose/application-manager', () => { status: 'Downloading', download_progress: 50, }, + node: { + image: 'node:latest', + status: 'Downloading', + download_progress: 0, + }, }, }, },