Skip to content

Commit

Permalink
Fix infinite loop with the bypass app cache option when returning fro…
Browse files Browse the repository at this point in the history
…m remote PWA
  • Loading branch information
Jaifroid committed May 7, 2023
1 parent 0254db5 commit 731ea72
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions www/js/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,10 @@ define(['jquery', 'zimArchiveLoader', 'uiUtil', 'settingsStore','abstractFilesys
}
})();

// Since contentInjectionMode can be overriden when returning from remote PWA to extension (for example), we have to prevent an infinite loop
// with code that warns the user to turn off the App Cache bypass in jQuery mode. Note that to turn OFF the bypass, we have to set the VALUE to true
params.appCache = params.contentInjectionMode === 'jquery' ? true : params.appCache;

/**
* Set the State and UI settings associated with parameters defined above
*/
Expand Down

0 comments on commit 731ea72

Please sign in to comment.