8000 TwigBundle exception/deprecation tweaks by ro0NL · Pull Request #24244 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content

TwigBundle exception/deprecation tweaks #24244

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

Merged
merged 4 commits into from
Sep 27, 2017
Merged
Changes from 1 commit
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
Prev Previous commit
Next Next commit
[TwigBundle] Make deprecations scream in logs
  • Loading branch information
ro0NL committed Sep 21, 2017
commit 0c10f97f986797347ecdfdfd4b7c53f4ecd87435
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,15 @@

<tbody>
{% for log in logs %}
<tr class="status-{{ log.priority >= 400 ? 'error' : log.priority >= 300 ? 'warning' : 'normal' }}">
{% if log.priority >= 400 %}
{% set status = 'error' %}
{% elseif log.priority >= 300 %}
{% set status = 'warning' %}
{% else %}
{% set severity = log.context.exception.severity|default(false) %}
{% set status = severity is constant('E_DEPRECATED') or severity is constant('E_USER_DEPRECATED') ? 'warning' : 'normal' %}
{% endif %}
<tr class="status-{{ status }}">
<td class="text-small" nowrap>
<span class="colored text-bold">{{ log.priorityName }}</span>
<span class="text-muted newline">{{ log.timestamp|date('H:i:s') }}</span>
Expand Down
0