@alfabit/keycloak 0.0.35 → 0.0.37

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@alfabit/keycloak",
3
3
  "private": false,
4
- "version": "0.0.35",
4
+ "version": "0.0.37",
5
5
  "type": "module",
6
6
  "license": "UNLICENSED",
7
7
  "main": "src/index.ts",
@@ -383,7 +383,7 @@ export async function initKeycloak() {
383
383
  };
384
384
 
385
385
  // Устанавливаем onLoad только если нужно
386
- if (KEYCLOAK_LOGIN_REQUIRED || (window.opener && APP_NAME !== AppNameEnum.PASSPORT)) {
386
+ if (KEYCLOAK_LOGIN_REQUIRED || (![AppNameEnum.PASSPORT, AppNameEnum.EXCHANGE].includes(APP_NAME))) {
387
387
  initOptions.onLoad = 'login-required';
388
388
  } else if (isNeedAuth) {
389
389
  initOptions.onLoad = 'check-sso';
@@ -391,6 +391,14 @@ export async function initKeycloak() {
391
391
  // window.location.href = getUrl() as string;
392
392
  }
393
393
 
394
+
395
+ console.log('>>>>>', {
396
+ KEYCLOAK_LOGIN_REQUIRED,
397
+ isNeedAuth,
398
+ initOptions
399
+ })
400
+
401
+
394
402
  if (!isNeedAuth) {
395
403
  clearTokens();
396
404
  } else {