From de299c64ae0d32f316d1679b79dd1ad72e1c0ed9 Mon Sep 17 00:00:00 2001 From: toasted-nutbread Date: Tue, 24 Nov 2020 11:54:08 -0500 Subject: Display updates (#1057) * Fix history assignment on the search page * Use clear instead of assigned * Simplify definitions assignment * Organize * Fix query not being cleared * Fix media loading * Fix potential issue with options not being assigned * Catch error when frameId is null, causing infinite loop * Fix frontend construction parameters --- ext/fg/js/popup-factory.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'ext/fg') diff --git a/ext/fg/js/popup-factory.js b/ext/fg/js/popup-factory.js index d63ed17a..252bcdf4 100644 --- a/ext/fg/js/popup-factory.js +++ b/ext/fg/js/popup-factory.js @@ -114,7 +114,7 @@ class PopupFactory { const popup = new Popup({ id, depth, - frameId, + frameId: this._frameId, ownerFrameId, childrenSupported }); @@ -129,6 +129,9 @@ class PopupFactory { popup.prepare(); return popup; } else { + if (frameId === null) { + throw new Error('Invalid frameId'); + } const useFrameOffsetForwarder = (parentPopupId === null); ({id, depth, frameId} = await api.crossFrame.invoke(frameId, 'getOrCreatePopup', { id, -- cgit v1.2.3