Skip to content

Commit 11c56ba

Browse files
committed
Merge branch '6.4' into 7.0
* 6.4: Remove 6.3 EOLed from Github template [Mailer] [Mailgun] Fix payload converter getReason [HttpFoundation] Fix clearing CHIPS cookies [AssetMapper] Turn debug on by default [AssetMapper] Fix JavaScript compiler load imports from JS strings [Notifier][Smsapi] Better docs for .com endpoint Fix exception if assets dir is missing in prod Update VERSION for 6.3.12 Update CHANGELOG for 6.3.12 Bump Symfony version to 5.4.36 Update VERSION for 5.4.35 Update CONTRIBUTORS for 5.4.35 Update CHANGELOG for 5.4.35
2 parents d974526 + 6a848e1 commit 11c56ba

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

EventListener/CookieClearingLogoutListener.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ public function onLogout(LogoutEvent $event): void
4040
}
4141

4242
foreach ($this->cookies as $cookieName => $cookieData) {
43-
$response->headers->clearCookie($cookieName, $cookieData['path'], $cookieData['domain'], $cookieData['secure'] ?? false, true, $cookieData['samesite'] ?? null);
43+
$response->headers->clearCookie($cookieName, $cookieData['path'], $cookieData['domain'], $cookieData['secure'] ?? false, true, $cookieData['samesite'] ?? null, $cookieData['partitioned'] ?? false);
4444
}
4545
}
4646

Tests/EventListener/CookieClearingLogoutListenerTest.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ public function testLogout()
2727
$event = new LogoutEvent(new Request(), null);
2828
$event->setResponse($response);
2929

30-
$listener = new CookieClearingLogoutListener(['foo' => ['path' => '/foo', 'domain' => 'foo.foo', 'secure' => true, 'samesite' => Cookie::SAMESITE_STRICT], 'foo2' => ['path' => null, 'domain' => null]]);
30+
$listener = new CookieClearingLogoutListener(['foo' => ['path' => '/foo', 'domain' => 'foo.foo', 'secure' => true, 'samesite' => Cookie::SAMESITE_STRICT, 'partitioned' => true], 'foo2' => ['path' => null, 'domain' => null]]);
3131

3232
$cookies = $response->headers->getCookies();
3333
$this->assertCount(0, $cookies);
@@ -43,6 +43,7 @@ public function testLogout()
4343
$this->assertEquals('foo.foo', $cookie->getDomain());
4444
$this->assertEquals(Cookie::SAMESITE_STRICT, $cookie->getSameSite());
4545
$this->assertTrue($cookie->isSecure());
46+
$this->assertTrue($cookie->isPartitioned());
4647
$this->assertTrue($cookie->isCleared());
4748

4849
$cookie = $cookies['']['/']['foo2'];
@@ -51,6 +52,7 @@ public function testLogout()
5152
$this->assertNull($cookie->getDomain());
5253
$this->assertNull($cookie->getSameSite());
5354
$this->assertFalse($cookie->isSecure());
55+
$this->assertFalse($cookie->isPartitioned());
5456
$this->assertTrue($cookie->isCleared());
5557
}
5658
}

0 commit comments

Comments
 (0)