From 7cfdec06170b5be288172ef8b36d067485c29fe9 Mon Sep 17 00:00:00 2001 From: Galen Charlton Date: Tue, 1 Sep 2020 10:52:50 -0400 Subject: [PATCH] fm-edit: deal with potential initialization sequence error --- Open-ILS/src/eg2/src/app/share/fm-editor/fm-editor.component.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) 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); } }, -- 2.11.0