diff --git a/src/Controller/AbstractController.php b/src/Controller/AbstractController.php index 5bfb7f2fb..8cf5b9df9 100644 --- a/src/Controller/AbstractController.php +++ b/src/Controller/AbstractController.php @@ -36,7 +36,8 @@ protected function getUserOrThrow(): User protected function validateCsrf(string $id, $token): void { if (!\is_string($token) || !$this->isCsrfTokenValid($id, $token)) { - throw new BadRequestHttpException("Invalid CSRF token, with ID: $id"); + $isTokenAString = \is_string($token); + throw new BadRequestHttpException("Invalid CSRF token, with ID: $id. Is token a string?: $isTokenAString"); } }