From b86d25cc465f0ad0c28d320e31bafdb0fa5a9833 Mon Sep 17 00:00:00 2001 From: Matthew Miller Date: Fri, 4 Mar 2022 22:33:42 -0800 Subject: Move WebAuthnError into structs for sharing --- packages/browser/src/helpers/identifyRegistrationError.ts | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) (limited to 'packages/browser/src/helpers/identifyRegistrationError.ts') diff --git a/packages/browser/src/helpers/identifyRegistrationError.ts b/packages/browser/src/helpers/identifyRegistrationError.ts index 4779f1a..8da0c97 100644 --- a/packages/browser/src/helpers/identifyRegistrationError.ts +++ b/packages/browser/src/helpers/identifyRegistrationError.ts @@ -1,4 +1,5 @@ import { isValidDomain } from './isValidDomain'; +import { WebAuthnError } from './structs'; export function identifyRegistrationError({ error, options }: { error: Error, @@ -73,10 +74,3 @@ export function identifyRegistrationError({ error, options }: { return error; } - -class WebAuthnError extends Error { - constructor(message: string) { - super(message); - this.name = 'WebAuthnError'; - } -} -- cgit v1.2.3