Passed
Push — master ( 971b39...24f529 )
by Sebastian
03:04
created
src/ArrayDataCollection.php 1 patch
Spacing   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@  discard block
 block discarded – undo
37 37
     /**
38 38
      * @param array<string,mixed> $data
39 39
      */
40
-    public function __construct(array $data=array())
40
+    public function __construct(array $data = array())
41 41
     {
42 42
         $this->data = $data;
43 43
     }
@@ -46,9 +46,9 @@  discard block
 block discarded – undo
46 46
      * @param ArrayDataCollection|array<string,mixed>|NULL $data
47 47
      * @return ArrayDataCollection
48 48
      */
49
-    public static function create($data=array()) : ArrayDataCollection
49
+    public static function create($data = array()) : ArrayDataCollection
50 50
     {
51
-        if($data instanceof self) {
51
+        if ($data instanceof self) {
52 52
             return $data;
53 53
         }
54 54
 
@@ -69,7 +69,7 @@  discard block
 block discarded – undo
69 69
      */
70 70
     public function setKeys(array $data) : self
71 71
     {
72
-        foreach($data as $key => $value)
72
+        foreach ($data as $key => $value)
73 73
         {
74 74
             $this->setKey($key, $value);
75 75
         }
@@ -137,11 +137,11 @@  discard block
 block discarded – undo
137 137
     {
138 138
         $value = $this->getKey($name);
139 139
 
140
-        if(is_string($value)) {
140
+        if (is_string($value)) {
141 141
             return $value;
142 142
         }
143 143
 
144
-        if(is_numeric($value)) {
144
+        if (is_numeric($value)) {
145 145
             return (string)$value;
146 146
         }
147 147
 
@@ -160,7 +160,7 @@  discard block
 block discarded – undo
160 160
     {
161 161
         $value = $this->getKey($name);
162 162
 
163
-        if(is_numeric($value)) {
163
+        if (is_numeric($value)) {
164 164
             return (int)$value;
165 165
         }
166 166
 
@@ -183,11 +183,11 @@  discard block
 block discarded – undo
183 183
         $value = $this->getKey($name);
184 184
 
185 185
         // Does not need to be decoded after all
186
-        if(is_array($value)) {
186
+        if (is_array($value)) {
187 187
             return $value;
188 188
         }
189 189
 
190
-        if(empty($value) || !is_string($value)) {
190
+        if (empty($value) || !is_string($value)) {
191 191
             return array();
192 192
         }
193 193
 
@@ -195,7 +195,7 @@  discard block
 block discarded – undo
195 195
         {
196 196
             $value = json_decode($value, true, 512, JSON_THROW_ON_ERROR);
197 197
 
198
-            if(is_array($value)) {
198
+            if (is_array($value)) {
199 199
                 return $value;
200 200
             }
201 201
 
@@ -225,7 +225,7 @@  discard block
 block discarded – undo
225 225
     {
226 226
         $value = $this->getKey($name);
227 227
 
228
-        if(is_array($value)) {
228
+        if (is_array($value)) {
229 229
             return $value;
230 230
         }
231 231
 
@@ -236,7 +236,7 @@  discard block
 block discarded – undo
236 236
     {
237 237
         $value = $this->getKey($name);
238 238
 
239
-        if(is_string($value)) {
239
+        if (is_string($value)) {
240 240
             $value = strtolower($value);
241 241
         }
242 242
 
@@ -254,7 +254,7 @@  discard block
 block discarded – undo
254 254
     {
255 255
         $value = $this->getKey($name);
256 256
 
257
-        if(is_numeric($value)) {
257
+        if (is_numeric($value)) {
258 258
             return (float)$value;
259 259
         }
260 260
 
Please login to merge, or discard this patch.