@hahnpro/hpc-api 4.1.2 → 5.0.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.
- package/dist/user.service.js +2 -2
- package/package.json +8 -8
package/dist/user.service.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.UserService = void 0;
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
|
-
const jwt_decode_1 =
|
|
5
|
+
const jwt_decode_1 = require("jwt-decode");
|
|
6
6
|
class UserService {
|
|
7
7
|
constructor(httpClient) {
|
|
8
8
|
this.httpClient = httpClient;
|
|
@@ -12,7 +12,7 @@ class UserService {
|
|
|
12
12
|
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
13
13
|
try {
|
|
14
14
|
const token = yield this.httpClient.getAccessToken();
|
|
15
|
-
const decode = (0, jwt_decode_1.
|
|
15
|
+
const decode = (0, jwt_decode_1.jwtDecode)(token);
|
|
16
16
|
return decode.realm_access.roles;
|
|
17
17
|
}
|
|
18
18
|
catch (err) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hahnpro/hpc-api",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "5.0.0",
|
|
4
4
|
"description": "Module for easy access to the HahnPRO API",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": {
|
|
@@ -24,21 +24,21 @@
|
|
|
24
24
|
"access": "public"
|
|
25
25
|
},
|
|
26
26
|
"dependencies": {
|
|
27
|
-
"axios": "~1.
|
|
27
|
+
"axios": "~1.6.0",
|
|
28
28
|
"eventsource": "^2.0.2",
|
|
29
29
|
"form-data": "^4.0.0",
|
|
30
|
-
"jose": "^
|
|
31
|
-
"jwt-decode": "^
|
|
30
|
+
"jose": "^5.0.1",
|
|
31
|
+
"jwt-decode": "^4.0.0",
|
|
32
32
|
"p-queue": "^6.6.2",
|
|
33
33
|
"ts-mixer": "^6.0.3",
|
|
34
|
-
"uuid": "^9.0.
|
|
34
|
+
"uuid": "^9.0.1"
|
|
35
35
|
},
|
|
36
36
|
"devDependencies": {
|
|
37
|
-
"@types/eventsource": "1.1.
|
|
38
|
-
"axios-mock-adapter": "^1.
|
|
37
|
+
"@types/eventsource": "1.1.14",
|
|
38
|
+
"axios-mock-adapter": "^1.22.0"
|
|
39
39
|
},
|
|
40
40
|
"engines": {
|
|
41
|
-
"node": ">=
|
|
41
|
+
"node": ">=v18"
|
|
42
42
|
},
|
|
43
43
|
"scripts": {
|
|
44
44
|
"build": "../../node_modules/.bin/tsc -p tsconfig.lib.json",
|