Commit 49a0906
committed
minor #42010 Improve usage of twig ternary (Seb33300)
This PR was merged into the 4.4 branch.
Discussion
----------
Improve usage of twig ternary
| Q | A
| ------------- | ---
| Branch? | 5.4
| Bug fix? | no
| New feature? | no
| Deprecations? | no
| Tickets | none
| License | MIT
| Doc PR | none
Remove useless `else` condition when using twig ternary:
> `{{ foo ? 'yes' }}` is the same as `{{ foo ? 'yes' : '' }}`
See: https://twig.symfony.com/doc/3.x/templates.html#other-operators
Commits
-------
4be962d323 Improve usage of twig ternary1 file changed
+2
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
| 8 | + | |
9 | 9 | | |
10 | | - | |
| 10 | + | |
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
| |||
0 commit comments