diff --git a/playground/server/api/passkey/login.post.ts b/playground/server/api/passkey/login.post.ts index 389767cf..5eb38606 100644 --- a/playground/server/api/passkey/login.post.ts +++ b/playground/server/api/passkey/login.post.ts @@ -1,7 +1,6 @@ import { base64URLStringToBuffer, bufferToBase64URLString } from '@simplewebauthn/browser' import { getRandomValues } from 'uncrypto' import type { AuthenticatorTransportFuture, PublicKeyCredentialRequestOptionsJSON } from '@simplewebauthn/types' -import definePasskeyAuthenticationEventHandler from '../../../../src/runtime/server/lib/webauthn/authenticate' // FIXME: autoimport interface PasskeyData { id: string diff --git a/playground/server/api/passkey/register.post.ts b/playground/server/api/passkey/register.post.ts index c67333e9..cc1ec7d2 100644 --- a/playground/server/api/passkey/register.post.ts +++ b/playground/server/api/passkey/register.post.ts @@ -1,7 +1,6 @@ import { bufferToBase64URLString } from '@simplewebauthn/browser' import { getRandomValues } from 'uncrypto' import type { PublicKeyCredentialCreationOptionsJSON } from '@simplewebauthn/types' -import definePasskeyRegistrationEventHandler from '../../../../src/runtime/server/lib/webauthn/register' // FIXME: autoimport export default definePasskeyRegistrationEventHandler({ storeChallenge: async (event, options) => { diff --git a/src/runtime/server/lib/webauthn/authenticate.ts b/src/runtime/server/lib/webauthn/authenticate.ts index 2a07e24d..b1446f97 100644 --- a/src/runtime/server/lib/webauthn/authenticate.ts +++ b/src/runtime/server/lib/webauthn/authenticate.ts @@ -32,7 +32,7 @@ interface PasskeyAuthenticationEventHandlerOptions { onError?: (event: H3Event, error: H3Error) => void | Promise } -export default function definePasskeyAuthenticationEventHandler({ +export function definePasskeyAuthenticationEventHandler({ storeChallenge, getChallenge, onSuccces, diff --git a/src/runtime/server/lib/webauthn/register.ts b/src/runtime/server/lib/webauthn/register.ts index a0e48dc2..6b228067 100644 --- a/src/runtime/server/lib/webauthn/register.ts +++ b/src/runtime/server/lib/webauthn/register.ts @@ -25,7 +25,7 @@ interface PasskeyRegistrationEventHandlerOptions { onError?: (event: H3Event, error: H3Error) => void | Promise } -export default function definePasskeyRegistrationEventHandler({ +export function definePasskeyRegistrationEventHandler({ storeChallenge, getChallenge, onSuccces,