Passed
Pull Request — develop (#10)
by Stephen
14:10
created
src/Support/Builder.php 1 patch
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -160,7 +160,7 @@  discard block
 block discarded – undo
160 160
 
161 161
         // Call API to get the response
162 162
         $response = $this->getClient()
163
-                         ->request($this->getPath());
163
+                            ->request($this->getPath());
164 164
 
165 165
         // Peel off the key if exist
166 166
         $response = $this->peelWrapperPropertyIfNeeded(Arr::wrap($response));
@@ -260,8 +260,8 @@  discard block
 block discarded – undo
260 260
     public function newInstance(): self
261 261
     {
262 262
         return (new static())->setClass($this->class)
263
-                             ->setClient($this->getClient())
264
-                             ->setParent($this->parentModel);
263
+                                ->setClient($this->getClient())
264
+                                ->setParent($this->parentModel);
265 265
     }
266 266
 
267 267
     /**
@@ -292,7 +292,7 @@  discard block
 block discarded – undo
292 292
         // Check for single response
293 293
         if (array_key_exists(
294 294
             $this->getModel()
295
-                 ->getResponseKey(),
295
+                    ->getResponseKey(),
296 296
             $properties
297 297
         )) {
298 298
             return $properties[$this->getModel()
@@ -302,7 +302,7 @@  discard block
 block discarded – undo
302 302
         // Check for collection of responses
303 303
         if (array_key_exists(
304 304
             $this->getModel()
305
-                 ->getResponseCollectionKey(),
305
+                    ->getResponseCollectionKey(),
306 306
             $properties
307 307
         )) {
308 308
             return $properties[$this->getModel()
Please login to merge, or discard this patch.
src/Support/Model.php 1 patch
Indentation   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -267,7 +267,7 @@  discard block
 block discarded – undo
267 267
         $foreignKey = $foreignKey ?? $this->assumeForeignKey($related);
268 268
 
269 269
         $builder = (new Builder())->setClass($related)
270
-                                  ->setClient($this->getClient());
270
+                                    ->setClient($this->getClient());
271 271
 
272 272
         return new BelongsTo($builder, $this, $foreignKey);
273 273
     }
@@ -288,8 +288,8 @@  discard block
 block discarded – undo
288 288
         $foreignKey = $foreignKey ?? $this->assumeForeignKey($related);
289 289
 
290 290
         $builder = (new Builder())->setClass($related)
291
-                                  ->setClient($this->getClient())
292
-                                  ->setParent($this);
291
+                                    ->setClient($this->getClient())
292
+                                    ->setParent($this);
293 293
 
294 294
         return new ChildOf($builder, $this, $foreignKey);
295 295
     }
@@ -310,7 +310,7 @@  discard block
 block discarded – undo
310 310
 
311 311
         try {
312 312
             $this->getClient()
313
-                 ->delete($this->getPath());
313
+                    ->delete($this->getPath());
314 314
 
315 315
             return true;
316 316
         } catch (GuzzleException $e) {
@@ -504,7 +504,7 @@  discard block
 block discarded – undo
504 504
     public function givenOne($related, $attributes, $reset = false): Model
505 505
     {
506 506
         return (new $related([], $this->parentModel))->setClient($this->getClient())
507
-                                                     ->newFromBuilder($reset ? reset($attributes) : $attributes);
507
+                                                        ->newFromBuilder($reset ? reset($attributes) : $attributes);
508 508
     }
509 509
 
510 510
     /**
@@ -520,8 +520,8 @@  discard block
 block discarded – undo
520 520
     public function hasMany($related): HasMany
521 521
     {
522 522
         $builder = (new Builder())->setClass($related)
523
-                                  ->setClient($this->getClient())
524
-                                  ->setParent($this);
523
+                                    ->setClient($this->getClient())
524
+                                    ->setParent($this);
525 525
 
526 526
         return new HasMany($builder, $this);
527 527
     }
@@ -670,7 +670,7 @@  discard block
 block discarded – undo
670 670
             if ($this->exists) {
671 671
                 // TODO: If we get null from the PUT, throw/handle exception
672 672
                 $response = $this->getClient()
673
-                                 ->put($this->getPath(), $this->getDirty());
673
+                                    ->put($this->getPath(), $this->getDirty());
674 674
 
675 675
                 // Record the changes
676 676
                 $this->syncChanges();
@@ -682,7 +682,7 @@  discard block
 block discarded – undo
682 682
             }
683 683
 
684 684
             $response = $this->getClient()
685
-                             ->post($this->getPath(), $this->toArray());
685
+                                ->post($this->getPath(), $this->toArray());
686 686
 
687 687
             $this->exists = true;
688 688
 
Please login to merge, or discard this patch.