mirror of
https://github.com/immich-app/immich.git
synced 2025-01-01 08:31:59 +00:00
fix(cli): uploadCounters increase only when files are uploaded (#6357)
* uploadcounters increase only when files are uploaded * move up totalSizeUploaded counter
This commit is contained in:
parent
d4146e3e6d
commit
b98d1bf9d3
1 changed files with 2 additions and 3 deletions
|
@ -107,6 +107,8 @@ export class Upload extends BaseCommand {
|
||||||
const formData = asset.getUploadFormData();
|
const formData = asset.getUploadFormData();
|
||||||
const res = await this.uploadAsset(formData);
|
const res = await this.uploadAsset(formData);
|
||||||
existingAssetId = res.data.id;
|
existingAssetId = res.data.id;
|
||||||
|
uploadCounter++;
|
||||||
|
totalSizeUploaded += asset.fileSize;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((options.album || options.albumName) && asset.albumName !== undefined) {
|
if ((options.album || options.albumName) && asset.albumName !== undefined) {
|
||||||
|
@ -127,9 +129,6 @@ export class Upload extends BaseCommand {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
totalSizeUploaded += asset.fileSize;
|
|
||||||
uploadCounter++;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
sizeSoFar += asset.fileSize;
|
sizeSoFar += asset.fileSize;
|
||||||
|
|
Loading…
Reference in a new issue