Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions service_container.rst
Original file line number Diff line number Diff line change
Expand Up @@ -534,8 +534,8 @@ You can also fetch parameters directly from the container::
{
// ...

// this ONLY works if you extend the base Controller
$adminEmail = $this->container->getParameter('admin_email');
// this ONLY works if you extend the base AbstractController
$adminEmail = $this->container->get('parameter_bag')->get('admin_email');

// or a shorter way!
// $adminEmail = $this->getParameter('admin_email');
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we will need to remove this line

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@xabbuh I made this minor reword while merging: eeeed92

Expand Down