From b7d3fb73ce390c1d9378a0ad91e3128d0548b7de Mon Sep 17 00:00:00 2001 From: Montassar Ghanmy Date: Wed, 12 Mar 2025 09:37:45 +0100 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20Fix=20upload=20into=20trash=20wh?= =?UTF-8?q?en=20modal=20is=20closed=20(#850)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/app/features/files/services/file-upload-service.ts | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/tdrive/frontend/src/app/features/files/services/file-upload-service.ts b/tdrive/frontend/src/app/features/files/services/file-upload-service.ts index c2ee3539..672fd86e 100644 --- a/tdrive/frontend/src/app/features/files/services/file-upload-service.ts +++ b/tdrive/frontend/src/app/features/files/services/file-upload-service.ts @@ -297,6 +297,9 @@ class FileUploadService { for (const rootKey of rootKeys) { if (rootKey in this.groupIds) { this.resetStates([rootKey]); + } else { + // remove from completed states + delete this.rootStates.completed[rootKey]; } } @@ -524,6 +527,10 @@ class FileUploadService { this.groupIds = {}; this.notify(); + + // reset the states for next upload + this.resetStates(Object.keys(this.rootStates.completed)); + this.notify(); } public cancelRootUpload(id: string) {