diff options
Diffstat (limited to 'ext/fg/js/frontend-initialize.js')
-rw-r--r-- | ext/fg/js/frontend-initialize.js | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/ext/fg/js/frontend-initialize.js b/ext/fg/js/frontend-initialize.js index 34be6bc6..e794c7c0 100644 --- a/ext/fg/js/frontend-initialize.js +++ b/ext/fg/js/frontend-initialize.js @@ -80,6 +80,7 @@ async function main() { }; let frontend = null; + let frontendPreparePromise = null; const applyOptions = async () => { const optionsContext = {depth: isSearchPage ? 0 : depth, url}; @@ -99,8 +100,10 @@ async function main() { if (frontend === null) { frontend = new Frontend(popup); - await frontend.prepare(); + frontendPreparePromise = frontend.prepare(); + await frontendPreparePromise; } else { + await frontendPreparePromise; if (isSearchPage) { const disabled = !options.scanning.enableOnSearchPage; frontend.setDisabledOverride(disabled); |