summary refs log tree commit diff
path: root/src/api/routes/users/@me/mfa/webauthn
diff options
context:
space:
mode:
authorRory& <root@rory.gay>2026-04-19 22:14:01 +0200
committerRory& <root@rory.gay>2026-04-19 22:45:37 +0200
commitaf29e6b178493c4d323edb9a7838d7731e40df86 (patch)
tree70e1357da5d86d72c29ba3dcfa0277e7519a8d44 /src/api/routes/users/@me/mfa/webauthn
parenteslint: no-promise-executor-return (diff)
downloadserver-ts-af29e6b178493c4d323edb9a7838d7731e40df86.tar.xz
eslint: arrow-body-style=as-needed
Diffstat (limited to 'src/api/routes/users/@me/mfa/webauthn')
-rw-r--r--src/api/routes/users/@me/mfa/webauthn/credentials/index.ts9
1 files changed, 2 insertions, 7 deletions
diff --git a/src/api/routes/users/@me/mfa/webauthn/credentials/index.ts b/src/api/routes/users/@me/mfa/webauthn/credentials/index.ts

index f99f7b3d..778fb9d8 100644 --- a/src/api/routes/users/@me/mfa/webauthn/credentials/index.ts +++ b/src/api/routes/users/@me/mfa/webauthn/credentials/index.ts
@@ -25,13 +25,8 @@ import { HTTPError } from "lambert-server"; import { CreateWebAuthnCredentialSchema, GenerateWebAuthnCredentialsSchema, WebAuthnPostSchema } from "@spacebar/schemas"; const router = Router({ mergeParams: true }); -const isGenerateSchema = (body: WebAuthnPostSchema): body is GenerateWebAuthnCredentialsSchema => { - return "password" in body; -}; - -const isCreateSchema = (body: WebAuthnPostSchema): body is CreateWebAuthnCredentialSchema => { - return "credential" in body; -}; +const isGenerateSchema = (body: WebAuthnPostSchema): body is GenerateWebAuthnCredentialsSchema => "password" in body; +const isCreateSchema = (body: WebAuthnPostSchema): body is CreateWebAuthnCredentialSchema => "credential" in body; function toArrayBuffer(buf: Buffer) { const ab = new ArrayBuffer(buf.length);