Test Failed
Push — main ( 6fe7e7...953723 )
by Dylan
03:16 queued 01:13
created
src/services/Collections.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -22,7 +22,7 @@  discard block
 block discarded – undo
22 22
     public function fetch(int $id): ?Collection
23 23
     {
24 24
         /** @var Collection|null $fetch */
25
-        $fetch = $this->_get('api/collections/collection' . $id);
25
+        $fetch = $this->_get('api/collections/collection'.$id);
26 26
         return $fetch;
27 27
     }
28 28
 
@@ -49,7 +49,7 @@  discard block
 block discarded – undo
49 49
     public function update(int $id, array $data): ?Collection
50 50
     {
51 51
         /** @var Collection|null $post */
52
-        $post = $this->_post('api/collections/collection/' . $id, $data);
52
+        $post = $this->_post('api/collections/collection/'.$id, $data);
53 53
         return $post;
54 54
     }
55 55
 
@@ -61,7 +61,7 @@  discard block
 block discarded – undo
61 61
      */
62 62
     public function delete(int $id): bool
63 63
     {
64
-        return $this->_delete('api/collections/collection/' . $id);
64
+        return $this->_delete('api/collections/collection/'.$id);
65 65
     }
66 66
 
67 67
     /**
Please login to merge, or discard this patch.
src/includes/functions.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -9,7 +9,7 @@
 block discarded – undo
9 9
     if (!$date) return null;
10 10
 
11 11
     try {
12
-        $date = new \DateTime($date . ' CET');
12
+        $date = new \DateTime($date.' CET');
13 13
         return $date;
14 14
     } catch (Exception $e) {
15 15
         error_log($e);
Please login to merge, or discard this patch.
src/resource/ListResource.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -212,20 +212,20 @@
 block discarded – undo
212 212
         $t = $this->getItems(1);
213 213
         $c = $this->count();
214 214
 
215
-        return (function () use ($t, $c) {
215
+        return (function() use ($t, $c) {
216 216
             $i = 0;
217 217
             $x = 0;
218 218
 
219 219
             while ($i < $c) {
220 220
                 if ($x === 0) {
221 221
                     $x = $this->_page_length;
222
-                    $t = $this->getItems((int) floor($i / $this->_page_length) + 1);
222
+                    $t = $this->getItems((int) floor($i / $this->_page_length)+1);
223 223
                 }
224 224
 
225
-                yield $i => $t[$this->_page_length - $x];
225
+                yield $i => $t[$this->_page_length-$x];
226 226
 
227 227
                 $x -= 1;
228
-                $i ++;
228
+                $i++;
229 229
             }
230 230
         })();
231 231
     }
Please login to merge, or discard this patch.
src/models/Model.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -34,19 +34,19 @@  discard block
 block discarded – undo
34 34
                     // Model or Object
35 35
                     if (!array_key_exists('field_name', $value)) {
36 36
                         $this->$field = ObjectFactory::make($client, $value);
37
-                    } else {
37
+                    }else {
38 38
                         // Has One Relation - Deprecated
39 39
                         $name = $value['field_name'];
40 40
                         $this->$name    = $value['field_value'];
41 41
                         $this->$field   = ObjectFactory::make($client, $value['object_data']);
42 42
                     }
43
-                } else {
43
+                }else {
44 44
                     // HasMany / ManyMany Relation
45 45
                     $list = [];
46 46
                     foreach ($value as $item) {
47 47
                         if (ArrayLib::is_associative($item)) {
48 48
                             $list[] = ObjectFactory::make($client, $item);
49
-                        } else {
49
+                        }else {
50 50
                             $list[] = $item;
51 51
                         }
52 52
                     }
@@ -83,7 +83,7 @@  discard block
 block discarded – undo
83 83
         if ($this->exists()) {
84 84
             if (!method_exists($service, 'update')) return $this;
85 85
             return $service->update($this->ID, $this->toArray());
86
-        } else {
86
+        }else {
87 87
             if (!method_exists($service, 'create')) return $this;
88 88
             return $service->create($this->toArray());
89 89
         }
Please login to merge, or discard this patch.
src/Client.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -21,11 +21,11 @@
 block discarded – undo
21 21
     public function __construct(string $_api_key, string $_api_secret, $_auth_domain = self::AUTH_DOMAIN)
22 22
     {
23 23
         if (!$_api_key) {
24
-            throw new InvalidArgumentException(static::class . ' parameter 1 should be your api key');
24
+            throw new InvalidArgumentException(static::class.' parameter 1 should be your api key');
25 25
         }
26 26
 
27 27
         if (!$_api_secret) {
28
-            throw new InvalidArgumentException(static::class . ' parameter 2 should be your api secret');
28
+            throw new InvalidArgumentException(static::class.' parameter 2 should be your api secret');
29 29
         }
30 30
 
31 31
         $this->_api_key = $_api_key;
Please login to merge, or discard this patch.