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 10fdb15 commit 0cef707Copy full SHA for 0cef707
packages/permission/src/index.ts
@@ -18,7 +18,7 @@ export const createPermission = (
18
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
19
if (navigator) {
20
navigator.permissions
21
- .query(typeof name === "string" ? { name: name as PermissionName } : name)
+ .query(typeof name === "string" ? { name } : name)
22
.then(setStatus)
23
.catch(error => {
24
if (error.name !== "TypeError" || (name !== "microphone" && name !== "camera")) {
0 commit comments