@auth0/auth0-spa-js 2.0.3 → 2.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/auth0-spa-js.development.js +5 -2
- package/dist/auth0-spa-js.development.js.map +1 -1
- package/dist/auth0-spa-js.production.esm.js +1 -1
- package/dist/auth0-spa-js.production.esm.js.map +1 -1
- package/dist/auth0-spa-js.production.js +1 -1
- package/dist/auth0-spa-js.production.js.map +1 -1
- package/dist/lib/auth0-spa-js.cjs.js +5 -2
- package/dist/lib/auth0-spa-js.cjs.js.map +1 -1
- package/dist/typings/version.d.ts +1 -1
- package/package.json +1 -1
- package/src/http.ts +9 -1
- package/src/version.ts +1 -1
- package/src/worker/token.worker.ts +1 -0
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
declare const _default: "2.0.
|
|
1
|
+
declare const _default: "2.0.4";
|
|
2
2
|
export default _default;
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"name": "@auth0/auth0-spa-js",
|
|
4
4
|
"description": "Auth0 SDK for Single Page Applications using Authorization Code Grant Flow with PKCE",
|
|
5
5
|
"license": "MIT",
|
|
6
|
-
"version": "2.0.
|
|
6
|
+
"version": "2.0.4",
|
|
7
7
|
"main": "dist/lib/auth0-spa-js.cjs.js",
|
|
8
8
|
"types": "dist/typings/index.d.ts",
|
|
9
9
|
"module": "dist/auth0-spa-js.production.esm.js",
|
package/src/http.ts
CHANGED
|
@@ -5,7 +5,11 @@ import {
|
|
|
5
5
|
|
|
6
6
|
import { sendMessage } from './worker/worker.utils';
|
|
7
7
|
import { FetchOptions } from './global';
|
|
8
|
-
import {
|
|
8
|
+
import {
|
|
9
|
+
GenericError,
|
|
10
|
+
MfaRequiredError,
|
|
11
|
+
MissingRefreshTokenError
|
|
12
|
+
} from './errors';
|
|
9
13
|
|
|
10
14
|
export const createAbortController = () => new AbortController();
|
|
11
15
|
|
|
@@ -142,6 +146,10 @@ export async function getJSON<T>(
|
|
|
142
146
|
throw new MfaRequiredError(error, errorMessage, data.mfa_token);
|
|
143
147
|
}
|
|
144
148
|
|
|
149
|
+
if (error === 'missing_refresh_token') {
|
|
150
|
+
throw new MissingRefreshTokenError(audience, scope);
|
|
151
|
+
}
|
|
152
|
+
|
|
145
153
|
throw new GenericError(error || 'request_error', errorMessage);
|
|
146
154
|
}
|
|
147
155
|
|
package/src/version.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export default '2.0.
|
|
1
|
+
export default '2.0.4';
|