Skip to content

Commit d1ea31f

Browse files
committed
do not translate null placeholders or titles
1 parent c4e8221 commit d1ea31f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

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)