Skip to content
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

Twig dump() function is NOT available on prod #7937

Closed
weaverryan opened this issue May 22, 2017 · 0 comments
Closed

Twig dump() function is NOT available on prod #7937

weaverryan opened this issue May 22, 2017 · 0 comments
Assignees
Labels

Comments

@weaverryan
Copy link
Member

@weaverryan weaverryan commented May 22, 2017

At the bottom of: http://symfony.com/doc/current/templating/debug.html

We say:

By default this means that the variables will be dumped in the dev environment but not the prod environment.

This seems to suggest that dump() will just do nothing in prod. But actually, as far as I can see, this function is not available at all, causing templates to fail in prod. That's because the DumpExtension from DebugBundle that provides dump() is not used, because DebugBundle is not enabled in the prod environment.

We should clarify that leaving dump() in your code is a big problem :).

@weaverryan weaverryan added the bug label May 22, 2017
@javiereguiluz javiereguiluz self-assigned this May 28, 2017
@javiereguiluz javiereguiluz added the hasPR label May 28, 2017
xabbuh added a commit that referenced this issue Jul 7, 2017
…d (javiereguiluz)

This PR was squashed before being merged into the 2.7 branch (closes #7954).

Discussion
----------

Reworded the note about dump() not being available in prod

This fixes #7937.

Commits
-------

830ac84 Reworded the note about dump() not being available in prod
@xabbuh xabbuh closed this Jul 7, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
4 participants
You can’t perform that action at this time.