Skip to content

Commit faabb81

Browse files
committed
Update controller.rst
Invalid flash example for php template leading to:: FatalErrorException: Error: Call to undefined method Symfony\Bundle\FrameworkBundle\Templating\Helper\SessionHelper::getFlashBag()
1 parent 4c3367f commit faabb81

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

book/controller.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -721,7 +721,7 @@ the ``notice`` message:
721721

722722
.. code-block:: html+php
723723

724-
<?php foreach ($view['session']->getFlashBag()->get('notice') as $message): ?>
724+
<?php foreach ($view['session']->getFlash('notice') as $message): ?>
725725
<div class="flash-notice">
726726
<?php echo "<div class='flash-error'>$message</div>" ?>
727727
</div>

0 commit comments

Comments
 (0)