You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat: wrap navigator.locks.request with plain promise to help zone.js (#989)
Wraps the `navigator.locks.request()` function with a plain Promise as
libraries such as zone.js patch this object to track execution context.
It appears that this browser API uses a native promise that's not
patched, causing the tracking context to be lost.
It is believed that wrapping this non-zone.js Promise returned by the
browser with a promise that's patched by zone.js can help the situation.
Related:
- supabase/supabase-js#936
- #830
'@supabase/gotrue-js: Error when querying Navigator LockManager state',
134
+
e
135
+
)
136
+
}
128
137
}
129
-
}
130
138
131
-
// Browser is not following the Navigator LockManager spec, it
132
-
// returned a null lock when we didn't use ifAvailable. So we can
133
-
// pretend the lock is acquired in the name of backward compatibility
134
-
// and user experience and just run the function.
135
-
console.warn(
136
-
'@supabase/gotrue-js: Navigator LockManager returned a null lock when using #request without ifAvailable set to true, it appears this browser is not following the LockManager spec https://developer.mozilla.org/en-US/docs/Web/API/LockManager/request'
137
-
)
139
+
// Browser is not following the Navigator LockManager spec, it
140
+
// returned a null lock when we didn't use ifAvailable. So we can
141
+
// pretend the lock is acquired in the name of backward compatibility
142
+
// and user experience and just run the function.
143
+
console.warn(
144
+
'@supabase/gotrue-js: Navigator LockManager returned a null lock when using #request without ifAvailable set to true, it appears this browser is not following the LockManager spec https://developer.mozilla.org/en-US/docs/Web/API/LockManager/request'
0 commit comments