diff --git a/src/Entity/AbstractTokenEntity.php b/src/Entity/AbstractTokenEntity.php index 4712f68d..d8d8af25 100644 --- a/src/Entity/AbstractTokenEntity.php +++ b/src/Entity/AbstractTokenEntity.php @@ -137,6 +137,10 @@ abstract class AbstractTokenEntity */ protected function formatScopes($unformatted = []) { + if (is_null($unformatted)) { + return []; + } + $scopes = []; foreach ($unformatted as $scope) { if ($scope instanceof ScopeEntity) {