Skip to content

Commit

Permalink
Replace for..if with |filter.
Browse files Browse the repository at this point in the history
  • Loading branch information
Igor Nikolaev committed Dec 19, 2019
1 parent edc8bbf commit 54aa46a
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions Resources/views/security/_menu.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@
'login': 'darvin_user_security_login',
'register': 'darvin_user_security_register',
'reset_password': 'darvin_user_password_reset_token_request',
} %}
{% if route != current_route %}
<a href="{{ path(route) }}">{{ ('security.menu.' ~ title)|trans }}</a>
{% endif %}
}|filter(route => route != current_route) %}
<a href="{{ path(route) }}">{{ ('security.menu.' ~ title)|trans }}</a>
{% endfor %}

0 comments on commit 54aa46a

Please sign in to comment.