Skip to content

Commit

Permalink
Fix hidden field fallback 'field.value'
Browse files Browse the repository at this point in the history
  • Loading branch information
NicoHood committed Jan 9, 2021
1 parent 03c9147 commit 7c630e2
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions templates/forms/fields/hidden/hidden.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

{% block field %}

{% set value = ?: field.value %}
{% set input_value = value is iterable ? value|join(',') : value|string %}

<input data-grav-field="hidden" data-grav-disabled="false" type="hidden" class="input" name="{{ (scope ~ field.name)|fieldName }}" value="{{ input_value|e('html_attr') }}" />
Expand Down

0 comments on commit 7c630e2

Please sign in to comment.