Skip to content

Commit a1e07b1

Browse files
committed
Changed -addEvidenceData- from skip-on-duplicate to replace-on-duplicate semantics
1 parent 7acc754 commit a1e07b1

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/app/model/evidence-store.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,10 @@ export class EvidenceStore {
7676
const newEntries = newEvidence[activityUuid];
7777
if (Array.isArray(newEntries)) {
7878
for (const entry of newEntries) {
79-
if (!this.isDuplicateEntry(activityUuid, entry)) {
79+
const existingIndex = this._evidence[activityUuid].findIndex(e => e.id === entry.id);
80+
if (existingIndex !== -1) {
81+
this._evidence[activityUuid][existingIndex] = entry;
82+
} else {
8083
this._evidence[activityUuid].push(entry);
8184
}
8285
}

0 commit comments

Comments
 (0)