From 60a7610ca6374bda9324c932c6b5c8bd731b3c14 Mon Sep 17 00:00:00 2001 From: Varun Patil Date: Fri, 19 May 2023 23:23:30 -0700 Subject: webpack: add nonce to unsupported-browser-redirect chunk Signed-off-by: Varun Patil Signed-off-by: nextcloud-command --- core/src/unsupported-browser-redirect.js | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'core') diff --git a/core/src/unsupported-browser-redirect.js b/core/src/unsupported-browser-redirect.js index 3ecf0b4dbe7..dd116b3a6ee 100644 --- a/core/src/unsupported-browser-redirect.js +++ b/core/src/unsupported-browser-redirect.js @@ -19,6 +19,11 @@ * along with this program. If not, see . */ +import { getRequestToken } from '@nextcloud/auth' + +// eslint-disable-next-line camelcase +__webpack_nonce__ = btoa(getRequestToken()) + if (!window.TESTING && !OC?.config?.no_unsupported_browser_warning) { window.addEventListener('DOMContentLoaded', async function() { const { testSupportedBrowser } = await import('./utils/RedirectUnsupportedBrowsers.js') -- cgit v1.2.3