@strapi/plugin-users-permissions 4.6.0-alpha.0 → 4.6.0-beta.0

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.
@@ -1,7 +1,7 @@
1
1
  import { useCallback, useReducer, useEffect, useRef } from 'react';
2
2
  import { useNotification } from '@strapi/helper-plugin';
3
3
  import reducer, { initialState } from './reducer';
4
- import axiosIntance from '../../utils/axiosInstance';
4
+ import axiosInstance from '../../utils/axiosInstance';
5
5
  import pluginId from '../../pluginId';
6
6
 
7
7
  const useFetchRole = (id) => {
@@ -29,7 +29,7 @@ const useFetchRole = (id) => {
29
29
  try {
30
30
  const {
31
31
  data: { role },
32
- } = await axiosIntance.get(`/${pluginId}/roles/${roleId}`);
32
+ } = await axiosInstance.get(`/${pluginId}/roles/${roleId}`);
33
33
 
34
34
  // Prevent updating state on an unmounted component
35
35
  if (isMounted.current) {
@@ -1,5 +1,5 @@
1
1
  import axios from 'axios';
2
- import { auth } from '@strapi/helper-plugin';
2
+ import { auth, wrapAxiosInstance } from '@strapi/helper-plugin';
3
3
 
4
4
  const instance = axios.create({
5
5
  baseURL: process.env.STRAPI_ADMIN_BACKEND_URL,
@@ -33,4 +33,6 @@ instance.interceptors.response.use(
33
33
  }
34
34
  );
35
35
 
36
- export default instance;
36
+ const wrapper = wrapAxiosInstance(instance);
37
+
38
+ export default wrapper;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@strapi/plugin-users-permissions",
3
- "version": "4.6.0-alpha.0",
3
+ "version": "4.6.0-beta.0",
4
4
  "description": "Protect your API with a full-authentication process based on JWT",
5
5
  "repository": {
6
6
  "type": "git",
@@ -27,8 +27,8 @@
27
27
  "test:front:watch:ce": "cross-env IS_EE=false jest --config ./jest.config.front.js --watchAll"
28
28
  },
29
29
  "dependencies": {
30
- "@strapi/helper-plugin": "4.6.0-alpha.0",
31
- "@strapi/utils": "4.6.0-alpha.0",
30
+ "@strapi/helper-plugin": "4.6.0-beta.0",
31
+ "@strapi/utils": "4.6.0-beta.0",
32
32
  "bcryptjs": "2.4.3",
33
33
  "grant-koa": "5.4.8",
34
34
  "jsonwebtoken": "^8.1.0",
@@ -41,7 +41,7 @@
41
41
  "react-intl": "5.25.1",
42
42
  "react-redux": "7.2.8",
43
43
  "react-router": "^5.2.0",
44
- "react-router-dom": "5.2.0",
44
+ "react-router-dom": "5.3.4",
45
45
  "request": "^2.83.0",
46
46
  "url-join": "4.0.1"
47
47
  },
@@ -50,7 +50,7 @@
50
50
  "@testing-library/react": "12.1.4",
51
51
  "@testing-library/react-hooks": "8.0.1",
52
52
  "@testing-library/user-event": "14.4.3",
53
- "msw": "0.42.3",
53
+ "msw": "0.49.1",
54
54
  "react-test-renderer": "^17.0.2"
55
55
  },
56
56
  "engines": {
@@ -64,5 +64,5 @@
64
64
  "required": true,
65
65
  "kind": "plugin"
66
66
  },
67
- "gitHead": "b7a87dcffc6f44e18eedef92e354096ffe32ce0c"
67
+ "gitHead": "c0c3365ad801d088a6ab6c4eb95a014078429747"
68
68
  }