Skip to content

Commit 4572bf3

Browse files
committed
Fix #251
1 parent f27cffd commit 4572bf3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Resources/templates/CommonAdmin/security_action.php.twig

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
{% if action is defined and action.credentials and action.credentials is not same as('AdmingenAllowed') %}
4343
$this->denyAccessUnlessValidateCredentials('{{ action.credentials }}');
4444
{% endif %}
45-
{% elseif credentials is defined and credentials is not same as('AdmingenAllowed') %}
45+
{% elseif credentials is defined and credentials is not empty and credentials is not same as('AdmingenAllowed') %}
4646
$this->denyAccessUnlessValidateCredentials('{{ credentials }}');
4747
{% endif %}
4848
{% endblock %}
@@ -52,7 +52,7 @@
5252
{% if action is defined and action.credentials and action.credentials is not same as('AdmingenAllowed') %}
5353
$this->denyAccessUnlessValidateCredentials('{{ action.credentials }}', ${{ builder.ModelClass }});
5454
{% endif %}
55-
{% elseif credentials and credentials is not same as('AdmingenAllowed') %}
55+
{% elseif credentials is defined and credentials is not empty and credentials is not same as('AdmingenAllowed') %}
5656
$this->denyAccessUnlessValidateCredentials('{{ credentials }}', ${{ builder.ModelClass }});
5757
{% endif %}
5858
{% endblock %}

0 commit comments

Comments
 (0)