We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bf2070d commit 939a060Copy full SHA for 939a060
packages/auth/src/platform_browser/index.ts
@@ -91,7 +91,11 @@ export function getAuth(app: FirebaseApp = getApp()): Auth {
91
92
const authTokenSyncPath = getExperimentalSetting('authTokenSyncURL');
93
// Only do the Cookie exchange in a secure context
94
- if (authTokenSyncPath && isSecureContext) {
+ if (
95
+ authTokenSyncPath &&
96
+ typeof isSecureContext === 'boolean' &&
97
+ isSecureContext
98
+ ) {
99
// Don't allow urls (XSS possibility), only paths on the same domain
100
const authTokenSyncUrl = new URL(authTokenSyncPath, location.origin);
101
if (location.origin === authTokenSyncUrl.origin) {
0 commit comments