@dvrd/dvr-controls 1.1.10 → 1.1.11
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/package.json +1 -1
- package/src/js/util/jwtUtil.ts +2 -2
package/package.json
CHANGED
package/src/js/util/jwtUtil.ts
CHANGED
|
@@ -7,13 +7,13 @@ import {debug, getSetting} from "./miscUtil";
|
|
|
7
7
|
|
|
8
8
|
let jwtToken: string | null = null;
|
|
9
9
|
|
|
10
|
-
export const getJwt = (): string | null => {
|
|
10
|
+
export const getJwt = (cookieName: string = 'JWT'): string | null => {
|
|
11
11
|
if (jwtToken && jwtToken.length) return jwtToken;
|
|
12
12
|
|
|
13
13
|
const jwt = getJwtFromStorage();
|
|
14
14
|
if (jwt && jwt.length) return jwt;
|
|
15
15
|
|
|
16
|
-
const cookieJwt = Cookies.get(
|
|
16
|
+
const cookieJwt = Cookies.get(cookieName);
|
|
17
17
|
if (cookieJwt && cookieJwt.length)
|
|
18
18
|
return cookieJwt;
|
|
19
19
|
return null;
|