8000 feature #5977 RequestStack parameter is required since 3.0 (leunggamciu) · symfony/symfony-docs@a5114d2 · GitHub
[go: up one dir, main page]

Skip to content

Commit a5114d2

Browse files
committed
feature #5977 RequestStack parameter is required since 3.0 (leunggamciu)
This PR was submitted for the 3.0 branch but it was merged into the 2.8 branch instead (closes #5977). Discussion ---------- RequestStack parameter is required since 3.0 | Q | A | ------------- | --- | Doc fix? | yes | New docs? | no | Applies to | 3.0 | Fixed tickets | N/A Commits ------- cb54c5e RequestStack parameter is required since 3.0
2 parents de11d3e + cb54c5e commit a5114d2

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

components/http_kernel/introduction.rst

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -616,6 +616,7 @@ However, the HttpKernel component comes with some built-in listeners and
616616
a built-in ControllerResolver that can be used to create a working example::
617617

618618
use Symfony\Component\HttpFoundation\Request;
619+
use Symfony\Component\HttpFoundation\RequestStack;
619620
use Symfony\Component\HttpFoundation\Response;
620621
use Symfony\Component\HttpKernel\HttpKernel;
621622
use Symfony\Component\EventDispatcher\EventDispatcher;
@@ -641,7 +642,7 @@ a built-in ControllerResolver that can be used to create a working example::
641642
$matcher = new UrlMatcher($routes, new RequestContext());
642643

643644
$dispatcher = new EventDispatcher();
644-
$dispatcher->addSubscriber(new RouterListener($matcher));
645+
$dispatcher->addSubscriber(new RouterListener($matcher, new RequestStack()));
645646

646647
$resolver = new ControllerResolver();
647648
$kernel = new HttpKernel($dispatcher, $resolver);

0 commit comments

Comments
 (0)
0