Passed
Push — main ( 52de70...4bac34 )
by Breno
02:11
created
src/Exception/Guard.php 1 patch
Spacing   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -37,8 +37,7 @@
 block discarded – undo
37 37
 
38 38
         $exception =
39 39
             $validationException instanceof ValidationExceptionInterface ?
40
-                $validationException :
41
-                new ValidationException();
40
+                $validationException : new ValidationException();
42 41
 
43 42
         $field = $result instanceof ResultByField ? $result->getField() : null;
44 43
         foreach ($result->getErrors() as $error) {
Please login to merge, or discard this patch.
src/Exception/ValidationException.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -18,7 +18,7 @@
 block discarded – undo
18 18
             }
19 19
         }
20 20
 
21
-        return $this->getMessage() . ":" . PHP_EOL . implode(PHP_EOL, $messages);
21
+        return $this->getMessage().":".PHP_EOL.implode(PHP_EOL, $messages);
22 22
     }
23 23
 
24 24
     /**
Please login to merge, or discard this patch.
src/RuleSet.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -39,7 +39,7 @@  discard block
 block discarded – undo
39 39
     /**
40 40
      * @throws Exception\ValidationExceptionInterface
41 41
      */
42
-    public static function forField(string $field, Rule|RuleSet ...$rules): self
42
+    public static function forField(string $field, Rule | RuleSet ...$rules): self
43 43
     {
44 44
         return new self($field, ...$rules);
45 45
     }
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
     /**
48 48
      * @throws Exception\ValidationExceptionInterface
49 49
      */
50
-    public static function withRules(Rule|RuleSet ...$rules): self
50
+    public static function withRules(Rule | RuleSet ...$rules): self
51 51
     {
52 52
         return new self(null, ...$rules);
53 53
     }
Please login to merge, or discard this patch.
src/MaybeBelongsToField.php 1 patch
Spacing   +2 added lines, -3 removed lines patch added patch discarded remove patch
@@ -42,11 +42,10 @@
 block discarded – undo
42 42
     /**
43 43
      * @throws ValidationExceptionInterface
44 44
      */
45
-    private function newEmptyValidationResult(): ValidationResult|ValidationResultByField
45
+    private function newEmptyValidationResult(): ValidationResult | ValidationResultByField
46 46
     {
47 47
         return
48 48
             $this->belongsToField() ?
49
-                new ValidationResultByField($this->getField()) :
50
-                ValidationResult::everythingIsOk();
49
+                new ValidationResultByField($this->getField()) : ValidationResult::everythingIsOk();
51 50
     }
52 51
 }
Please login to merge, or discard this patch.