Passed
Push — main ( 926316...d9c688 )
by Dimitri
02:57
created
src/Rules/DoesntEndWith.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -18,6 +18,6 @@
 block discarded – undo
18 18
      */
19 19
     public function check($value): bool
20 20
     {
21
-        return ! parent::check($value);
21
+        return !parent::check($value);
22 22
     }
23 23
 }
Please login to merge, or discard this patch.
src/Rules/Cidr.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -44,6 +44,6 @@
 block discarded – undo
44 44
         }
45 45
 
46 46
         // and it should be between 0 and 32 inclusive
47
-        return ! ($parts[1] < 0 || $parts[1] > 32);
47
+        return !($parts[1] < 0 || $parts[1] > 32);
48 48
     }
49 49
 }
Please login to merge, or discard this patch.
src/Rules/Password.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -165,7 +165,7 @@  discard block
 block discarded – undo
165 165
      */
166 166
     public function check($value): bool
167 167
     {
168
-        if (! is_string($value)) {
168
+        if (!is_string($value)) {
169 169
             return false;
170 170
         }
171 171
 
@@ -181,16 +181,16 @@  discard block
 block discarded – undo
181 181
             $this->validation->getMessages(),
182 182
         );
183 183
 
184
-        if ($this->mixedCase && ! preg_match('/(\p{Ll}+.*\p{Lu})|(\p{Lu}+.*\p{Ll})/u', $value)) {
184
+        if ($this->mixedCase && !preg_match('/(\p{Ll}+.*\p{Lu})|(\p{Lu}+.*\p{Ll})/u', $value)) {
185 185
             $this->validation->errors()->add($attribute, static::name() . '.mixed', $this->processTranslate('password.mixed'));
186 186
         }
187
-        if ($this->letters && ! preg_match('/\pL/u', $value)) {
187
+        if ($this->letters && !preg_match('/\pL/u', $value)) {
188 188
             $this->validation->errors()->add($attribute, static::name() . '.letters', $this->processTranslate('password.letters'));
189 189
         }
190
-        if ($this->symbols && ! preg_match('/\p{Z}|\p{S}|\p{P}/u', $value)) {
190
+        if ($this->symbols && !preg_match('/\p{Z}|\p{S}|\p{P}/u', $value)) {
191 191
             $this->validation->errors()->add($attribute, static::name() . '.symbols', $this->processTranslate('password.symbols'));
192 192
         }
193
-        if ($this->numbers && ! preg_match('/\pN/u', $value)) {
193
+        if ($this->numbers && !preg_match('/\pN/u', $value)) {
194 194
             $this->validation->errors()->add($attribute, static::name() . '.numbers', $this->processTranslate('password.numbers'));
195 195
         }
196 196
 
Please login to merge, or discard this patch.
src/Rules/Titlecase.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -23,12 +23,12 @@
 block discarded – undo
23 23
      */
24 24
     public function check($value): bool
25 25
     {
26
-        if (! is_string($value)) {
26
+        if (!is_string($value)) {
27 27
             return false;
28 28
         }
29 29
 
30 30
         foreach ($this->getWords($value) as $word) {
31
-            if (! $this->isValidWord($word)) {
31
+            if (!$this->isValidWord($word)) {
32 32
                 return false;
33 33
             }
34 34
         }
Please login to merge, or discard this patch.
src/Rules/Missing.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -18,6 +18,6 @@
 block discarded – undo
18 18
      */
19 19
     public function check($value): bool
20 20
     {
21
-        return ! $this->validation->hasValue($this->attribute->getKey());
21
+        return !$this->validation->hasValue($this->attribute->getKey());
22 22
     }
23 23
 }
Please login to merge, or discard this patch.
src/Rules/Gtin.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -42,11 +42,11 @@
 block discarded – undo
42 42
      */
43 43
     public function check($value): bool
44 44
     {
45
-        if (! is_numeric($value)) {
45
+        if (!is_numeric($value)) {
46 46
             return false;
47 47
         }
48 48
 
49
-        if (! $this->hasAllowedLength($value)) {
49
+        if (!$this->hasAllowedLength($value)) {
50 50
             return false;
51 51
         }
52 52
 
Please login to merge, or discard this patch.
src/Rules/Distinct.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -43,7 +43,7 @@  discard block
 block discarded – undo
43 43
      */
44 44
     public function check($value): bool
45 45
     {
46
-        if (! is_array($value)) {
46
+        if (!is_array($value)) {
47 47
             if (null === $attribute = $this->attribute->getPrimaryAttribute()) {
48 48
                 return false;
49 49
             }
@@ -55,7 +55,7 @@  discard block
 block discarded – undo
55 55
         }
56 56
 
57 57
         if (in_array('ignore_case', $this->parameters, true)) {
58
-            $value = array_map(function ($v) {
58
+            $value = array_map(function($v) {
59 59
                 if (is_string($v)) {
60 60
                     $v = strtolower($v);
61 61
                 }
Please login to merge, or discard this patch.
src/Rules/TypeFloat.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
     public function check($value): bool
22 22
     {
23 23
         // https://www.php.net/manual/en/function.is-float.php#117304
24
-        if (! is_scalar($value)) {
24
+        if (!is_scalar($value)) {
25 25
             return false;
26 26
         }
27 27
 
Please login to merge, or discard this patch.
src/Rules/Date.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -34,11 +34,11 @@
 block discarded – undo
34 34
      */
35 35
     public function check($value): bool
36 36
     {
37
-        if ((! is_string($value) && ! is_numeric($value) && ! ($value instanceof DateTimeInterface))) {
37
+        if ((!is_string($value) && !is_numeric($value) && !($value instanceof DateTimeInterface))) {
38 38
             return false;
39 39
         }
40 40
 
41
-        if (! empty($format = $this->parameter('format'))) {
41
+        if (!empty($format = $this->parameter('format'))) {
42 42
             $this->message .= ' format';
43 43
 
44 44
             $date = DateTime::createFromFormat($format, $value);
Please login to merge, or discard this patch.