From: Galen Charlton Date: Tue, 1 Sep 2020 14:52:50 +0000 (-0400) Subject: fm-edit: deal with potential initialization sequence error X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=7cfdec06170b5be288172ef8b36d067485c29fe9;p=working%2FEvergreen.git fm-edit: deal with potential initialization sequence error --- diff --git a/Open-ILS/src/eg2/src/app/share/fm-editor/fm-editor.component.ts b/Open-ILS/src/eg2/src/app/share/fm-editor/fm-editor.component.ts index d396ae8873..8dfa4e08dd 100644 --- a/Open-ILS/src/eg2/src/app/share/fm-editor/fm-editor.component.ts +++ b/Open-ILS/src/eg2/src/app/share/fm-editor/fm-editor.component.ts @@ -621,7 +621,9 @@ export class FmRecordEditorComponent this.pcrud[this.mode]([recToSave]).toPromise().then( result => { this.recordSaved.emit(result); - this.fmEditForm.form.markAsPristine(); + if (this.fmEditForm) { + this.fmEditForm.form.markAsPristine(); + } this.successStr.current().then(msg => this.toast.success(msg)); if (this.isDialog()) { this.record = undefined; this.close(result); } },