Skip to content

Commit

Permalink
feature #5977 RequestStack parameter is required since 3.0 (leunggamciu)
Browse files Browse the repository at this point in the history
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
  • Loading branch information
wouterj committed Dec 17, 2015
2 parents de11d3e + cb54c5e commit a5114d2
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion components/http_kernel/introduction.rst
Original file line number Diff line number Diff line change
Expand Up @@ -616,6 +616,7 @@ However, the HttpKernel component comes with some built-in listeners and
a built-in ControllerResolver that can be used to create a working example::

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

$dispatcher = new EventDispatcher();
$dispatcher->addSubscriber(new RouterListener($matcher));
$dispatcher->addSubscriber(new RouterListener($matcher, new RequestStack()));

$resolver = new ControllerResolver();
$kernel = new HttpKernel($dispatcher, $resolver);
Expand Down

0 comments on commit a5114d2

Please sign in to comment.