8000 do not translate null placeholders or titles · symfony/symfony@2ee24a0 · GitHub
[go: up one dir, main page]

Skip to content

Commit 2ee24a0

Browse files
committed
do not translate null placeholders or titles
1 parent f6dc826 commit 2ee24a0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Symfony/Bridge/Twig/Resources/views/Form/form_div_layout.html.twig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -399,7 +399,7 @@
399399
{%- for attrname, attrvalue in attr -%}
400400
{{- " " -}}
401401
{%- if attrname in ['placeholder', 'title'] -%}
402-
{{- attrname }}="{{ translation_domain is same as(false) ? attrvalue : attrvalue|trans({}, translation_domain) }}"
402+
{{- attrname }}="{{ translation_domain is same as(false) or attrvalue is null ? attrvalue : attrvalue|trans({}, translation_domain) }}"
403403
{%- elseif attrvalue is same as(true) -%}
404404
{{- attrname }}="{{ attrname }}"
405405
{%- elseif attrvalue is not same as(false) -%}

0 commit comments

Comments
 (0)
0