From 6a332d5c1e248d976c44eecc67161b4d1b401a0e Mon Sep 17 00:00:00 2001 From: bobzel Date: Tue, 14 May 2024 23:16:04 -0400 Subject: post merge fixes for sarah-ai-visualizatoin --- src/client/views/DocComponent.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/client/views/DocComponent.tsx') diff --git a/src/client/views/DocComponent.tsx b/src/client/views/DocComponent.tsx index 94e84e647..e5752dcd2 100644 --- a/src/client/views/DocComponent.tsx +++ b/src/client/views/DocComponent.tsx @@ -233,7 +233,7 @@ export function ViewBoxAnnotatableComponent

() { const annoDocs = Doc.Get(targetDataDoc, annotationKey ?? this.annotationKey, true) as List; // get the dataDoc directly ... when using templates there may be some default items already there, but we can't change them, so we copy them below (should really be some kind of inheritance since the template contents could change) if (annoDocs instanceof List) annoDocs.push(...added.filter(add => !annoDocs.includes(add))); - else targetDataDoc[annotationKey ?? this.annotationKey] = new List([...added, ...(annoDocs === undefined ? DocListCast(targetDataDoc[annotationKey ?? this.annotationKey]) : [])]); + else targetDataDoc[annotationKey || this.annotationKey] = new List([...added, ...(annoDocs === undefined ? DocListCast(targetDataDoc[annotationKey ?? this.annotationKey]) : [])]); targetDataDoc[(annotationKey ?? this.annotationKey) + '_modificationDate'] = new DateField(); } } -- cgit v1.2.3-70-g09d2