Skip to content

Added app.token to the list of global variables #7191

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed
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
Added app.token to the list of global variables
  • Loading branch information
javiereguiluz committed Nov 28, 2016
commit fea03975d266dd2e81a68dde524ab30f9355c23f
12 changes: 7 additions & 5 deletions reference/twig_reference.rst
Original file line number Diff line number Diff line change
Expand Up @@ -715,11 +715,13 @@ needed objects and values. It is an instance of

The available attributes are:

* ``app.user``
* ``app.request``
* ``app.session``
* ``app.environment``
* ``app.debug``
* ``app.user`` (a PHP object representing the current user)
* ``app.token`` (a :class:`Symfony\\Component\\Security\\Core\\Authentication\\Token\\TokenInterface`
object representing the security token)
* ``app.request`` (a :class:``Symfony\\Component\\HttpFoundation\\Request`` object)
* ``app.session`` (a :class:``Symfony\\Component\\HttpFoundation\\Session\\Session`` object)
* ``app.environment`` (a string with the name of the execution environment)
* ``app.debug`` (a boolean telling whether the debug mode is enabled in the app)

Symfony Standard Edition Extensions
-----------------------------------
Expand Down