Skip to content

Commit 181cc98

Browse files
fix: dispatch webauthn:unsupported for browsers missing parseOptionsFromJSON
Closes #113.
1 parent 10cad17 commit 181cc98

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

app/assets/javascript/devise/webauthn.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,9 @@ function isWebAuthnSupported() {
33
navigator.credentials &&
44
navigator.credentials.create &&
55
navigator.credentials.get &&
6-
window.PublicKeyCredential
6+
window.PublicKeyCredential &&
7+
PublicKeyCredential.parseCreationOptionsFromJSON &&
8+
PublicKeyCredential.parseRequestOptionsFromJSON
79
);
810
}
911

0 commit comments

Comments
 (0)