From d9c09f0648bbb1bdaf1b27a8c330bba4e420627f Mon Sep 17 00:00:00 2001 From: Stas Demin Date: Wed, 16 Oct 2024 08:02:22 +0300 Subject: [PATCH] hotfix: realise 3.23.0 fixes --- src/Helpers/CoreTokenStorage.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Helpers/CoreTokenStorage.php b/src/Helpers/CoreTokenStorage.php index bb8e8f3..0d0cb6b 100644 --- a/src/Helpers/CoreTokenStorage.php +++ b/src/Helpers/CoreTokenStorage.php @@ -85,7 +85,7 @@ private static function getBaseUrlFromToken(string $token): ?string { $arToken = explode('.', $token); - return json_decode(base64_decode($arToken[2]), true, 512, JSON_THROW_ON_ERROR)['endpoint'] ?? null; + return json_decode(base64_decode(count($arToken) - 1), true, 512, JSON_THROW_ON_ERROR)['endpoint'] ?? null; } /**