Преглед на файлове

fix bad securities rules

Olivier Massot преди 1 година
родител
ревизия
f6dfd8148b
променени са 2 файла, в които са добавени 2 реда и са изтрити 2 реда
  1. 1 1
      src/Entity/Organization/Parameters.php
  2. 1 1
      src/Entity/Organization/Subdomain.php

+ 1 - 1
src/Entity/Organization/Parameters.php

@@ -28,7 +28,7 @@ use Symfony\Component\Validator\Constraints as Assert;
 #[ApiResource(
     operations: [
         new Get(
-            security: 'is_granted("ROLE_ORGANIZATION_VIEW" and object.getOrganization().getId() == user.getOrganization().getId()'
+            security: 'is_granted("ROLE_ORGANIZATION_VIEW") and object.getOrganization().getId() == user.getOrganization().getId()'
         ),
         new Put(
             security: 'is_granted("ROLE_ORGANIZATION") and object.getOrganization().getId() == user.getOrganization().getId()'

+ 1 - 1
src/Entity/Organization/Subdomain.php

@@ -30,7 +30,7 @@ use Symfony\Component\Validator\Constraints as Assert;
 #[ApiResource(
     operations: [
         new Get(
-            security: 'is_granted("ROLE_ORGANIZATION_VIEW" and object.getOrganization().getId() == user.getOrganization().getId()'
+            security: 'is_granted("ROLE_ORGANIZATION_VIEW") and object.getOrganization().getId() == user.getOrganization().getId()'
         ),
         new Put(
             security: 'is_granted("ROLE_ORGANIZATION") and object.getOrganization().getId() == user.getOrganization().getId()'