mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-19 17:38:19 +08:00
core&ui: upgrade simplewebauthn
This commit is contained in:
9 files changed
+20
-26
No files matched your search
@@ -27,7 +27,7 @@
|
||||
"@hydrooj/utils": "workspace:^",
|
||||
"@sentry/browser": "^8.54.0",
|
||||
"@sentry/webpack-plugin": "^3.1.2",
|
||||
"@simplewebauthn/browser": "9.0.1",
|
||||
"@simplewebauthn/browser": "13.1.0",
|
||||
"@svgr/webpack": "^8.1.0",
|
||||
"@types/jquery": "^3.5.32",
|
||||
"@types/jquery.transit": "^0.9.33",
|
||||
|
||||
@@ -68,7 +68,7 @@ async function enableAuthn(type: string) {
|
||||
let credential;
|
||||
try {
|
||||
console.log(authnInfo);
|
||||
credential = await startRegistration(authnInfo.authOptions);
|
||||
credential = await startRegistration({ optionsJSON: authnInfo.authOptions });
|
||||
} catch (err) {
|
||||
Notification.error(i18n('Failed to get credential: {0}', err));
|
||||
return;
|
||||
|
||||
@@ -18,7 +18,7 @@ async function verifywebauthn($form) {
|
||||
return null;
|
||||
}
|
||||
Notification.info(i18n('Please follow the instructions on your device to complete the verification.'));
|
||||
const result = await startAuthentication(authnInfo.authOptions)
|
||||
const result = await startAuthentication({ optionsJSON: authnInfo.authOptions })
|
||||
.catch((e) => {
|
||||
Notification.error(i18n('Failed to get credential: {0}', e));
|
||||
return null;
|
||||
|
||||
Reference in new issue
Block a user