Completed
Branch master (91621e)
by Neomerx
01:35
created
src/Authorization/PolicyDecision/Algorithms/BaseAlgorithmInterface.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -37,8 +37,8 @@  discard block
 block discarded – undo
37 37
     public static function evaluateTargets(
38 38
         ContextInterface $context,
39 39
         array $optimizedTargets,
40
-        ?LoggerInterface $logger
41
-    ): Generator;
40
+        ? LoggerInterface $logger
41
+    ) : Generator;
42 42
 
43 43
     /**
44 44
      * @param ContextInterface     $context
@@ -52,6 +52,6 @@  discard block
 block discarded – undo
52 52
         ContextInterface $context,
53 53
         int $match,
54 54
         array $encodedItem,
55
-        ?LoggerInterface $logger
56
-    ): array;
55
+        ? LoggerInterface $logger
56
+    ) : array;
57 57
 }
Please login to merge, or discard this patch.
src/Authorization/PolicyDecision/Algorithms/RulesDenyOverrides.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -41,8 +41,8 @@
 block discarded – undo
41 41
         ContextInterface $context,
42 42
         array $optimizedTargets,
43 43
         array $serializedRules,
44
-        ?LoggerInterface $logger
45
-    ): array {
44
+        ? LoggerInterface $logger
45
+    ) : array {
46 46
         return static::evaluateDenyOverrides($context, $optimizedTargets, $serializedRules, $logger);
47 47
     }
48 48
 }
Please login to merge, or discard this patch.
src/Authorization/PolicyDecision/Algorithms/BaseRuleAlgorithm.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -102,8 +102,8 @@
 block discarded – undo
102 102
         ContextInterface $context,
103 103
         int $match,
104 104
         array $encodedItem,
105
-        ?LoggerInterface $logger
106
-    ): array {
105
+        ? LoggerInterface $logger
106
+    ) : array {
107 107
         return static::evaluateRule($context, $match, $encodedItem, $logger);
108 108
     }
109 109
 
Please login to merge, or discard this patch.
src/Authorization/PolicyDecision/Algorithms/RulesFirstApplicable.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -41,8 +41,8 @@
 block discarded – undo
41 41
         ContextInterface $context,
42 42
         array $optimizedTargets,
43 43
         array $encodedRules,
44
-        ?LoggerInterface $logger
45
-    ): array {
44
+        ? LoggerInterface $logger
45
+    ) : array {
46 46
         return self::evaluateFirstApplicable($context, $optimizedTargets, $encodedRules, $logger);
47 47
     }
48 48
 }
Please login to merge, or discard this patch.
src/Authorization/PolicyDecision/Algorithms/RulesDenyUnlessPermit.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -41,8 +41,8 @@
 block discarded – undo
41 41
         ContextInterface $context,
42 42
         array $optimizedTargets,
43 43
         array $encodedRules,
44
-        ?LoggerInterface $logger
45
-    ): array {
44
+        ? LoggerInterface $logger
45
+    ) : array {
46 46
         return self::evaluateDenyUnlessPermit($context, $optimizedTargets, $encodedRules, $logger);
47 47
     }
48 48
 }
Please login to merge, or discard this patch.
Authorization/PolicyDecision/Algorithms/PoliciesOrSetsPermitUnlessDeny.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -41,8 +41,8 @@
 block discarded – undo
41 41
         ContextInterface $context,
42 42
         array $optimizedTargets,
43 43
         array $encPoliciesOrSets,
44
-        ?LoggerInterface $logger
45
-    ): array {
44
+        ? LoggerInterface $logger
45
+    ) : array {
46 46
         return self::evaluatePermitUnlessDeny($context, $optimizedTargets, $encPoliciesOrSets, $logger);
47 47
     }
48 48
 }
Please login to merge, or discard this patch.
src/Authorization/PolicyDecision/Algorithms/RulesPermitOverrides.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -41,8 +41,8 @@
 block discarded – undo
41 41
         ContextInterface $context,
42 42
         array $optimizedTargets,
43 43
         array $serializedRules,
44
-        ?LoggerInterface $logger
45
-    ): array {
44
+        ? LoggerInterface $logger
45
+    ) : array {
46 46
         return static::evaluatePermitOverrides($context, $optimizedTargets, $serializedRules, $logger);
47 47
     }
48 48
 }
Please login to merge, or discard this patch.
src/Authorization/PolicyDecision/Algorithms/Encoder.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -237,7 +237,7 @@  discard block
 block discarded – undo
237 237
      *
238 238
      * @return string|null
239 239
      */
240
-    public static function targetName(array $encodedTarget): ?string
240
+    public static function targetName(array $encodedTarget): ? string
241 241
     {
242 242
         assert(static::isTarget($encodedTarget));
243 243
 
@@ -249,7 +249,7 @@  discard block
 block discarded – undo
249 249
      *
250 250
      * @return array|null
251 251
      */
252
-    public static function targetAnyOfs(array $encodedTarget): ?array
252
+    public static function targetAnyOfs(array $encodedTarget): ? array
253 253
     {
254 254
         assert(static::isTarget($encodedTarget));
255 255
 
@@ -285,7 +285,7 @@  discard block
 block discarded – undo
285 285
      *
286 286
      * @return array|null
287 287
      */
288
-    public static function ruleEffect(array $encodedRule): ?array
288
+    public static function ruleEffect(array $encodedRule): ? array
289 289
     {
290 290
         assert(static::isRule($encodedRule));
291 291
 
@@ -297,7 +297,7 @@  discard block
 block discarded – undo
297 297
      *
298 298
      * @return callable|null
299 299
      */
300
-    public static function ruleCondition(array $encodedRule): ?callable
300
+    public static function ruleCondition(array $encodedRule): ? callable
301 301
     {
302 302
         assert(static::isRule($encodedRule));
303 303
 
@@ -333,7 +333,7 @@  discard block
 block discarded – undo
333 333
      *
334 334
      * @return string|null
335 335
      */
336
-    public static function policyName(array $encodedPolicy): ?string
336
+    public static function policyName(array $encodedPolicy): ? string
337 337
     {
338 338
         assert(static::isPolicy($encodedPolicy));
339 339
 
@@ -503,7 +503,7 @@  discard block
 block discarded – undo
503 503
      *
504 504
      * @return callable|null
505 505
      */
506
-    private static function serializeMethod(MethodInterface $method = null): ?callable
506
+    private static function serializeMethod(MethodInterface $method = null): ? callable
507 507
     {
508 508
         return $method === null ? null : $method->getCallable();
509 509
     }
Please login to merge, or discard this patch.
src/Authorization/PolicyDecision/Algorithms/DefaultTargetSerializeTrait.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -40,8 +40,8 @@  discard block
 block discarded – undo
40 40
     public static function evaluateTargets(
41 41
         ContextInterface $context,
42 42
         array $optimizedTargets,
43
-        ?LoggerInterface $logger
44
-    ): Generator {
43
+        ? LoggerInterface $logger
44
+    ) : Generator {
45 45
         foreach ($optimizedTargets as $ruleId => $anyOf) {
46 46
             $match = static::evaluateTarget($context, $anyOf, $logger);
47 47
 
@@ -63,8 +63,8 @@  discard block
 block discarded – undo
63 63
     protected static function evaluateTarget(
64 64
         ContextInterface $context,
65 65
         array $target,
66
-        ?LoggerInterface $logger
67
-    ): int {
66
+        ? LoggerInterface $logger
67
+    ) : int {
68 68
         /** @see http://docs.oasis-open.org/xacml/3.0/xacml-3.0-core-spec-os-en.html #7.11 (table 4) */
69 69
 
70 70
         assert(Encoder::isTarget($target) === true);
@@ -124,7 +124,7 @@  discard block
 block discarded – undo
124 124
      *
125 125
      * @return array
126 126
      */
127
-    protected static function encodeTarget(?TargetInterface $target): array
127
+    protected static function encodeTarget(? TargetInterface $target) : array
128 128
     {
129 129
         $name   = null;
130 130
         $anyOfs = null;
Please login to merge, or discard this patch.