fix(symfony): check if the request if stateless

This commit is contained in:
Younes ENNAJI
2023-12-10 01:17:56 +01:00
parent b69dc4e834
commit 25ebe37eeb
+3 -1
View File
@@ -68,7 +68,9 @@ final class SessionBag implements BagInterface
$session = $this->session->getCurrentRequest()->getSession();
}
if (null !== $session) {
$isStateless = $this->session->getCurrentRequest()->attributes->has('_stateless');
if (null !== $session && !$isStateless) {
return $this->session = $session;
}