Passed
Push — main ( 46058f...95f3d8 )
by Breno
01:32
created
src/Validator.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -39,7 +39,7 @@  discard block
 block discarded – undo
39 39
      * @param Rule|RuleSet ...$rules
40 40
      * @return $this
41 41
      */
42
-    public function field(string $field, Rule|RuleSet ...$rules): self
42
+    public function field(string $field, Rule | RuleSet ...$rules): self
43 43
     {
44 44
         $ruleSet = $this->ruleSets[$field] ?? RuleSet::of($field);
45 45
         $this->ruleSets[$field] = $ruleSet->add(...$rules);
@@ -52,7 +52,7 @@  discard block
 block discarded – undo
52 52
         $errorReporting = new ErrorReporting;
53 53
         foreach ($this->ruleSets as $field => $fieldRuleSet) {
54 54
             $fieldRuleSet = $fieldRuleSet->withField($field);
55
-            if (! $this->shouldValidate($fieldRuleSet, $data)) {
55
+            if (!$this->shouldValidate($fieldRuleSet, $data)) {
56 56
                 continue;
57 57
             }
58 58
 
@@ -117,7 +117,7 @@  discard block
 block discarded – undo
117 117
      * @return static
118 118
      * @throws ReflectionException if the class does not exist
119 119
      */
120
-    public static function fromProperties(string|object $objectOrClass, ?int $filter = null): self
120
+    public static function fromProperties(string | object $objectOrClass, ?int $filter = null): self
121 121
     {
122 122
         $instance = new self;
123 123
         $instance->ruleSets = RuleSetFactory::fromProperties($objectOrClass, $filter);
Please login to merge, or discard this patch.
src/StopOnFailure.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
     protected function setStopSign(int $stopSign): void
20 20
     {
21
-        if (! in_array($stopSign, StopSign::allowed())) {
21
+        if (!in_array($stopSign, StopSign::allowed())) {
22 22
             throw new InvalidArgumentException(sprintf('Invalid stop sign (%s)', $stopSign));
23 23
         }
24 24
 
Please login to merge, or discard this patch.
src/Rules/UseRuleSet.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -21,7 +21,7 @@
 block discarded – undo
21 21
     use BelongsToField, StopOnFailure, Priority;
22 22
 
23 23
     public function __construct(
24
-        private object|string $objectOrClass,
24
+        private object | string $objectOrClass,
25 25
         private string $property,
26 26
         int $stopOnFailure = StopSign::DONT_STOP,
27 27
         int $priority = Prioritable::LOWEST_PRIORITY
Please login to merge, or discard this patch.