Skip to content

Commit

Permalink
Make unsupported browser check asynchronous
Browse files Browse the repository at this point in the history
This check is very expensive, and will pass almost 100% of the time.

Related #36728
Depends on #38329

Signed-off-by: Varun Patil <[email protected]>
  • Loading branch information
pulsejet authored and szaimen committed May 19, 2023
1 parent 8cca865 commit 947c1cc
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions core/src/unsupported-browser-redirect.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,9 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/

import { testSupportedBrowser } from './utils/RedirectUnsupportedBrowsers.js'

if (!window.TESTING && !OC?.config?.no_unsupported_browser_warning) {
testSupportedBrowser()
window.addEventListener('DOMContentLoaded', async function() {
const { testSupportedBrowser } = await import('./utils/RedirectUnsupportedBrowsers.js')
testSupportedBrowser()
})
}

0 comments on commit 947c1cc

Please sign in to comment.