diff --git a/src-ui/src/app/services/document-list-view.service.ts b/src-ui/src/app/services/document-list-view.service.ts index e67ceda4b..b0d246a32 100644 --- a/src-ui/src/app/services/document-list-view.service.ts +++ b/src-ui/src/app/services/document-list-view.service.ts @@ -161,7 +161,10 @@ export class DocumentListViewService { this.reload() } else { let errorMessage - if (Object.keys(error.error).length > 0) { + if ( + typeof error.error !== 'string' && + Object.keys(error.error).length > 0 + ) { // e.g. { archive_serial_number: Array } errorMessage = Object.keys(error.error) .map((fieldName) => {