UNPKG

@aws-amplify/auth

Version:
1 lines 2.11 kB
{"version":3,"file":"constants.mjs","sources":["../../../src/errors/constants.ts"],"sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport { AuthError } from './AuthError';\nexport const USER_UNAUTHENTICATED_EXCEPTION = 'UserUnAuthenticatedException';\nexport const USER_ALREADY_AUTHENTICATED_EXCEPTION = 'UserAlreadyAuthenticatedException';\nexport const DEVICE_METADATA_NOT_FOUND_EXCEPTION = 'DeviceMetadataNotFoundException';\nexport const AUTO_SIGN_IN_EXCEPTION = 'AutoSignInException';\nexport const INVALID_REDIRECT_EXCEPTION = 'InvalidRedirectException';\nexport const invalidRedirectException = new AuthError({\n name: INVALID_REDIRECT_EXCEPTION,\n message: 'signInRedirect or signOutRedirect had an invalid format or was not found.',\n recoverySuggestion: 'Please make sure the signIn/Out redirect in your oauth config is valid.',\n});\nexport const INVALID_ORIGIN_EXCEPTION = 'InvalidOriginException';\nexport const invalidOriginException = new AuthError({\n name: INVALID_ORIGIN_EXCEPTION,\n message: 'redirect is coming from a different origin. The oauth flow needs to be initiated from the same origin',\n recoverySuggestion: 'Please call signInWithRedirect from the same origin.',\n});\nexport const OAUTH_SIGNOUT_EXCEPTION = 'OAuthSignOutException';\nexport const TOKEN_REFRESH_EXCEPTION = 'TokenRefreshException';\nexport const UNEXPECTED_SIGN_IN_INTERRUPTION_EXCEPTION = 'UnexpectedSignInInterruptionException';\n"],"names":[],"mappings":";;AAAA;AACA;AAEY,MAAC,8BAA8B,GAAG,+BAA+B;AACjE,MAAC,oCAAoC,GAAG,oCAAoC;AAC5E,MAAC,mCAAmC,GAAG,kCAAkC;AACzE,MAAC,sBAAsB,GAAG,sBAAsB;AAChD,MAAC,0BAA0B,GAAG,2BAA2B;AACzD,MAAC,wBAAwB,GAAG,IAAI,SAAS,CAAC;AACtD,IAAI,IAAI,EAAE,0BAA0B;AACpC,IAAI,OAAO,EAAE,2EAA2E;AACxF,IAAI,kBAAkB,EAAE,yEAAyE;AACjG,CAAC,EAAE;AACS,MAAC,wBAAwB,GAAG,yBAAyB;AACrD,MAAC,sBAAsB,GAAG,IAAI,SAAS,CAAC;AACpD,IAAI,IAAI,EAAE,wBAAwB;AAClC,IAAI,OAAO,EAAE,uGAAuG;AACpH,IAAI,kBAAkB,EAAE,sDAAsD;AAC9E,CAAC,EAAE;AACS,MAAC,uBAAuB,GAAG,wBAAwB;AACnD,MAAC,uBAAuB,GAAG,wBAAwB;AACnD,MAAC,yCAAyC,GAAG;;;;"}