Skip to content

Commit 99a1fcc

Browse files
committed
replaced deprecated Twig sameas test by same as
1 parent e25aca7 commit 99a1fcc

File tree

4 files changed

+15
-15
lines changed

4 files changed

+15
-15
lines changed

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
{% block form_label -%}
1111
{% spaceless %}
12-
{% if label is sameas(false) %}
12+
{% if label is same as(false) %}
1313
<div class="{{ block('form_label_class') }}"></div>
1414
{% else %}
1515
{% set label_attr = label_attr|merge({class: (label_attr.class|default('') ~ ' ' ~ block('form_label_class'))|trim}) %}

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -166,12 +166,12 @@
166166
{% if parent_label_class is defined %}
167167
{% set label_attr = label_attr|merge({class: (label_attr.class|default('') ~ ' ' ~ parent_label_class)|trim}) %}
168168
{% endif %}
169-
{% if label is not sameas(false) and label is empty %}
169+
{% if label is not same as(false) and label is empty %}
170170
{% set label = name|humanize %}
171171
{% endif %}
172172
<label{% for attrname, attrvalue in label_attr %} {{ attrname }}="{{ attrvalue }}"{% endfor %}>
173173
{{- widget|raw -}}
174-
{{- label is not sameas(false) ? (translation_domain is sameas(false) ? label : label|trans({}, translation_domain)) -}}
174+
{{- label is not same as(false) ? (translation_domain is same as(false) ? label : label|trans({}, translation_domain)) -}}
175175
</label>
176176
{% endif %}
177177
{% endblock checkbox_radio_label %}

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

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -74,13 +74,13 @@
7474
{%- block choice_widget_options -%}
7575
{% for group_label, choice in options %}
7676
{%- if choice is iterable -%}
77-
<optgroup label="{{ choice_translation_domain is sameas(false) ? group_label : group_label|trans({}, choice_translation_domain) }}">
77+
<optgroup label="{{ choice_translation_domain is same as(false) ? group_label : group_label|trans({}, choice_translation_domain) }}">
7878
{% set options = choice %}
7979
{{- block('choice_widget_options') -}}
8080
</optgroup>
8181
{%- else -%}
8282
{% set attr = choice.attr %}
83-
<option value="{{ choice.value }}" {{ block('attributes') }}{% if choice is selectedchoice(value) %} selected="selected"{% endif %}>{{ choice_translation_domain is sameas(false) ? choice.label : choice.label|trans({}, choice_translation_domain) }}</option>
83+
<option value="{{ choice.value }}" {{ block('attributes') }}{% if choice is selectedchoice(value) %} selected="selected"{% endif %}>{{ choice_translation_domain is same as(false) ? choice.label : choice.label|trans({}, choice_translation_domain) }}</option>
8484
{%- endif -%}
8585
{% endfor %}
8686
{%- endblock choice_widget_options -%}
@@ -220,7 +220,7 @@
220220
{% set label = name|humanize %}
221221
{%- endif -%}
222222
{%- endif -%}
223-
<label{% for attrname, attrvalue in label_attr %} {{ attrname }}="{{ attrvalue }}"{% endfor %}>{{ translation_domain is sameas(false) ? label : label|trans({}, translation_domain) }}</label>
223+
<label{% for attrname, attrvalue in label_attr %} {{ attrname }}="{{ attrvalue }}"{% endfor %}>{{ translation_domain is same as(false) ? label : label|trans({}, translation_domain) }}</label>
224224
{%- endif -%}
225225
{%- endblock form_label -%}
226226

@@ -321,9 +321,9 @@
321321
{{- " " -}}
322322
{%- if attrname in ['placeholder', 'title'] -%}
323323
{{- attrname }}="{{ attrvalue|trans({}, translation_domain) }}"
324-
{%- elseif attrvalue is sameas(true) -%}
324+
{%- elseif attrvalue is same as(true) -%}
325325
{{- attrname }}="{{ attrname }}"
326-
{%- elseif attrvalue is not sameas(false) -%}
326+
{%- elseif attrvalue is not same as(false) -%}
327327
{{- attrname }}="{{ attrvalue }}"
328328
{%- endif -%}
329329
{%- endfor -%}
@@ -335,9 +335,9 @@
335335
{{- " " -}}
336336
{%- if attrname in ['placeholder', 'title'] -%}
337337
{{- attrname }}="{{ attrvalue|trans({}, translation_domain) }}"
338-
{%- elseif attrvalue is sameas(true) -%}
338+
{%- elseif attrvalue is same as(true) -%}
339339
{{- attrname }}="{{ attrname }}"
340-
{%- elseif attrvalue is not sameas(false) -%}
340+
{%- elseif attrvalue is not same as(false) -%}
341341
{{- attrname }}="{{ attrvalue }}"
342342
{%- endif -%}
343343
{%- endfor -%}
@@ -349,9 +349,9 @@
349349
{{- " " -}}
350350
{%- if attrname in ['placeholder', 'title'] -%}
351351
{{- attrname }}="{{ attrvalue|trans({}, translation_domain) }}"
352-
{%- elseif attrvalue is sameas(true) -%}
352+
{%- elseif attrvalue is same as(true) -%}
353353
{{- attrname }}="{{ attrname }}"
354-
{%- elseif attrvalue is not sameas(false) -%}
354+
{%- elseif attrvalue is not same as(false) -%}
355355
{{- attrname }}="{{ attrvalue }}"
356356
{%- endif -%}
357357
{%- endfor -%}
@@ -362,9 +362,9 @@
362362
{{- " " -}}
363363
{%- if attrname in ['placeholder', 'title'] -%}
364364
{{- attrname }}="{{ attrvalue|trans({}, translation_domain) }}"
365-
{%- elseif attrvalue is sameas(true) -%}
365+
{%- elseif attrvalue is same as(true) -%}
366366
{{- attrname }}="{{ attrname }}"
367-
{%- elseif attrvalue is not sameas(false) -%}
367+
{%- elseif attrvalue is not same as(false) -%}
368368
{{- attrname }}="{{ attrvalue }}"
369369
{%- endif -%}
370370
{%- endfor -%}

src/Symfony/Bundle/WebProfilerBundle/Resources/views/Collector/form.html.twig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -610,7 +610,7 @@
610610
<th>{{ option }}</th>
611611
<td><pre>{{ value }}</pre></td>
612612
<td>
613-
{% if data.resolved_options[option] is sameas(value) %}
613+
{% if data.resolved_options[option] is same as(value) %}
614614
<em>same as passed value</em>
615615
{% else %}
616616
<pre>{{ data.resolved_options[option] }}</pre>

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy