Skip to content

Commit b2cd345

Browse files
committed
Fix app.user check
1 parent 82b0009 commit b2cd345

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cookbook/controller/error_pages.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ end-user, create a new template located at
5656
by your error pages), because the router runs before the firewall. If
5757
the router throws an exception (for instance, when the route does not
5858
match), then using ``is_granted`` will throw a further exception. You
59-
can use ``is_granted`` safely by saying ``{% if app.user and is_granted('...') %}``.
59+
can use ``is_granted`` safely by saying ``{% if app.user is not null and is_granted('...') %}``.
6060

6161
.. tip::
6262

0 commit comments

Comments
 (0)