]> git.ipfire.org Git - thirdparty/paperless-ngx.git/commitdiff
bugfix dismissing wrong status messages
authorjonaswinkler <jonas.winkler@jpwinkler.de>
Mon, 15 Feb 2021 13:52:47 +0000 (14:52 +0100)
committerjonaswinkler <jonas.winkler@jpwinkler.de>
Mon, 15 Feb 2021 13:52:47 +0000 (14:52 +0100)
src-ui/src/app/services/consumer-status.service.ts

index 23df0871f61a23876a2752e6a5837827c67d0d1a..e0328217568bd1c1438e6df10df16ba9219e5fec 100644 (file)
@@ -169,7 +169,12 @@ export class ConsumerStatusService {
   }
 
   dismiss(status: FileStatus) {
-    let index = this.consumerStatus.findIndex(s => s.filename == status.filename)
+    let index
+    if (status.taskId != null) {
+      index = this.consumerStatus.findIndex(s => s.taskId == status.taskId)
+    } else {
+      index = this.consumerStatus.findIndex(s => s.filename == status.filename)
+    }
 
     if (index > -1) {
       this.consumerStatus.splice(index, 1)