0
0
mirror of https://github.com/go-gitea/gitea.git synced 2026-01-08 03:54:35 +01:00

fix webAuthn insecure error view (#36165) (#36179)

backport #36165

Signed-off-by: a1012112796 <1012112796@qq.com>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
This commit is contained in:
a1012112796 2025-12-18 00:49:29 +08:00 committed by GitHub
parent a99ccfdf74
commit 522cc25921
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -11,13 +11,8 @@ export async function initUserAuthWebAuthn() {
return;
}
// webauthn is only supported on secure contexts
if (!window.isSecureContext) {
hideElem(elSignInPasskeyBtn);
return;
}
if (!detectWebAuthnSupport()) {
if (elSignInPasskeyBtn) hideElem(elSignInPasskeyBtn);
return;
}