diff --git a/src/Service/SecurityService.php b/src/Service/SecurityService.php index 868254fe4..6af0041e7 100644 --- a/src/Service/SecurityService.php +++ b/src/Service/SecurityService.php @@ -54,11 +54,7 @@ public function authenticateUser(Create $token): PasswordAuthenticatedUserInterf public function isAllowed(string $token): bool { - $userIds = $this->tmpStoreResolver->getIdsByTag($token); - if(count($userIds) === 0 || count($userIds) > 1) { - return false; - } - $entry = $this->tmpStoreResolver->get($userIds[0]); - return $entry && $entry->getTag() === $token; + $entry = $this->tmpStoreResolver->get($token); + return $entry !== null && $entry->getId() === $token; } } \ No newline at end of file