Skip to content

Commit 88e23e1

Browse files
Seb33300fabpot
authored andcommitted
Improve usage of twig ternary
1 parent 48329a5 commit 88e23e1

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Resources/views/Collector/security.html.twig

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@
55
{% block toolbar %}
66
{% if collector.token %}
77
{% set is_authenticated = collector.enabled and collector.authenticated %}
8-
{% set color_code = is_authenticated ? '' : 'yellow' %}
8+
{% set color_code = not is_authenticated ? 'yellow' %}
99
{% else %}
10-
{% set color_code = collector.enabled ? 'red' : '' %}
10+
{% set color_code = collector.enabled ? 'red' %}
1111
{% endif %}
1212

1313
{% set icon %}

0 commit comments

Comments
 (0)