Passed
Push — main ( 11848c...4790f2 )
by Breno
02:08
created
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.
src/AbstractRule.php 1 patch
Spacing   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -41,8 +41,7 @@  discard block
 block discarded – undo
41 41
     {
42 42
         return
43 43
             $this->hasOwnMessage() ?
44
-                Translator::translate(static::MESSAGE) :
45
-                Translator::translate(static::MESSAGE, $this->className());
44
+                Translator::translate(static::MESSAGE) : Translator::translate(static::MESSAGE, $this->className());
46 45
     }
47 46
 
48 47
     /** @inheritDoc */
@@ -50,8 +49,7 @@  discard block
 block discarded – undo
50 49
     {
51 50
         return
52 51
             $this->isValid($input, $context) ?
53
-                ErrorReporting::success() :
54
-                (new ErrorReporting)->addError($this->message(), $this->getField(), $this);
52
+                ErrorReporting::success() : (new ErrorReporting)->addError($this->message(), $this->getField(), $this);
55 53
     }
56 54
 
57 55
     protected function className(): string
Please login to merge, or discard this patch.
src/Priority.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@
 block discarded – undo
28 28
 
29 29
     public static function sortByPriority(array &$haystack): void
30 30
     {
31
-        uasort($haystack, function ($a, $b) {
31
+        uasort($haystack, function($a, $b) {
32 32
             $prorityOfA = $a instanceof Prioritable ? $a->getPriority() : Prioritable::LOWEST_PRIORITY;
33 33
             $prorityOfB = $b instanceof Prioritable ? $b->getPriority() : Prioritable::LOWEST_PRIORITY;
34 34
 
Please login to merge, or discard this patch.
src/Comparator.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -11,7 +11,7 @@
 block discarded – undo
11 11
     public function compare(mixed $a, string $operator, mixed $b): bool
12 12
     {
13 13
         return
14
-        match ($operator) {
14
+        match($operator) {
15 15
             Operator::EQUAL => $a == $b,
16 16
             Operator::EXACTLY => $a === $b,
17 17
             Operator::GREATER_THAN => $a > $b,
Please login to merge, or discard this patch.
src/Rules/DateTime/DateTimeCompareWith.php 1 patch
Spacing   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -34,8 +34,7 @@
 block discarded – undo
34 34
             $other = fn() => new DateTimeImmutable($context[$this->other]);
35 35
             $datetime =
36 36
                 $input instanceof DateTimeInterface ?
37
-                    $input :
38
-                    new DateTimeImmutable($input);
37
+                    $input : new DateTimeImmutable($input);
39 38
 
40 39
             return array_key_exists($this->other, $context)
41 40
                 && $this->compare($datetime, $this->operator, $other);
Please login to merge, or discard this patch.
src/Rules/DateTime/DateTimeCompare.php 1 patch
Spacing   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -34,8 +34,7 @@
 block discarded – undo
34 34
             $other = new DateTimeImmutable($this->datetime);
35 35
             $datetime =
36 36
                 $input instanceof DateTimeInterface ?
37
-                    $input :
38
-                    new DateTimeImmutable($input);
37
+                    $input : new DateTimeImmutable($input);
39 38
 
40 39
             return $this->compare($datetime, $this->operator, $other);
41 40
         } catch (Throwable) {
Please login to merge, or discard this patch.