Skip to content

Commit f3e69cd

Browse files
committed
[DSC-2876] fix: handle string authority values in section-form-operations service
1 parent 4381651 commit f3e69cd

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

src/app/submission/sections/form/section-form-operations.service.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -250,7 +250,11 @@ export class SectionFormOperationsService {
250250
if ((event.model as DsDynamicInputModel).hasAuthority) {
251251
if (Array.isArray(value)) {
252252
value.forEach((authority, index) => {
253-
authority = Object.assign(new VocabularyEntry(), authority, { language });
253+
if (typeof authority === 'string') {
254+
authority = Object.assign(new VocabularyEntry(), { value: authority, language });
255+
} else {
256+
authority = Object.assign(new VocabularyEntry(), authority, { language });
257+
}
254258
value[index] = authority;
255259
});
256260
fieldValue = value;

0 commit comments

Comments
 (0)