Skip to content
This repository was archived by the owner on May 31, 2024. It is now read-only.

Commit 397955f

Browse files
committed
adapted merge to 2.5
1 parent fca8c99 commit 397955f

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

Http/RememberMe/ResponseListener.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313

1414
use Symfony\Component\HttpKernel\Event\FilterResponseEvent;
1515
use Symfony\Component\HttpKernel\KernelEvents;
16-
use Symfony\Component\HttpKernel\HttpKernelInterface;
1716
use Symfony\Component\EventDispatcher\EventSubscriberInterface;
1817

1918
/**
@@ -28,7 +27,7 @@ class ResponseListener implements EventSubscriberInterface
2827
*/
2928
public function onKernelResponse(FilterResponseEvent $event)
3029
{
31-
if (HttpKernelInterface::MASTER_REQUEST !== $event->getRequestType()) {
30+
if (!$event->isMasterRequest()) {
3231
return;
3332
}
3433

Http/Tests/RememberMe/ResponseListenerTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ private function getEvent($request, $response, $type = HttpKernelInterface::MAST
9494
->getMock();
9595

9696
$event->expects($this->any())->method('getRequest')->will($this->returnValue($request));
97-
$event->expects($this->any())->method('getRequestType')->will($this->returnValue($type));
97+
$event->expects($this->any())->method('isMasterRequest')->will($this->returnValue($type === HttpKernelInterface::MASTER_REQUEST));
9898
$event->expects($this->any())->method('getResponse')->will($this->returnValue($response));
9999

100100
return $event;

0 commit comments

Comments
 (0)