Completed
Push — master ( 135018...0f0a30 )
by Andrey
04:47
created
src/Relations/HasRelationships.php 2 patches
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -376,7 +376,7 @@  discard block
 block discarded – undo
376 376
      * @return BelongsToMany
377 377
      */
378 378
     public function belongsToMany($related, $table = null, $foreignPivotKey = null, $relatedPivotKey = null,
379
-                                  $parentKey = null, $relatedKey = null, $relation = null)
379
+                                    $parentKey = null, $relatedKey = null, $relation = null)
380 380
     {
381 381
         if (is_null($relation)) {
382 382
             $relation = $this->guessBelongsToManyRelation();
@@ -474,8 +474,8 @@  discard block
 block discarded – undo
474 474
      * @return MorphToMany
475 475
      */
476 476
     protected function newMorphToMany(Builder $query, Model $parent, $name, $table, $foreignPivotKey,
477
-                                      $relatedPivotKey, $parentKey, $relatedKey,
478
-                                      $relationName = null, $inverse = false)
477
+                                        $relatedPivotKey, $parentKey, $relatedKey,
478
+                                        $relationName = null, $inverse = false)
479 479
     {
480 480
         return new MorphToMany($query, $parent, $name, $table, $foreignPivotKey, $relatedPivotKey, $parentKey, $relatedKey,
481 481
             $relationName, $inverse);
@@ -494,7 +494,7 @@  discard block
 block discarded – undo
494 494
      * @return MorphToMany
495 495
      */
496 496
     public function morphedByMany($related, $name, $table = null, $foreignPivotKey = null,
497
-                                  $relatedPivotKey = null, $parentKey = null, $relatedKey = null)
497
+                                    $relatedPivotKey = null, $parentKey = null, $relatedKey = null)
498 498
     {
499 499
         $foreignPivotKey = $foreignPivotKey ?: $this->getForeignKey();
500 500
 
Please login to merge, or discard this patch.
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -514,11 +514,11 @@
 block discarded – undo
514 514
      */
515 515
     protected function guessBelongsToManyRelation()
516 516
     {
517
-        $caller = Arr::first(debug_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS), function ($trace) {
518
-            return ! in_array($trace['function'], Model::$manyMethods);
517
+        $caller = Arr::first(debug_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS), function($trace) {
518
+            return !in_array($trace['function'], Model::$manyMethods);
519 519
         });
520 520
 
521
-        return ! is_null($caller) ? $caller['function'] : null;
521
+        return !is_null($caller) ? $caller['function'] : null;
522 522
     }
523 523
 
524 524
     /**
Please login to merge, or discard this patch.
src/Relations/Relation.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -71,7 +71,7 @@  discard block
 block discarded – undo
71 71
      */
72 72
     protected function getKeys(array $models, $key = null)
73 73
     {
74
-        return array_unique(array_values(array_map(function ($value) use ($key) {
74
+        return array_unique(array_values(array_map(function($value) use ($key) {
75 75
             return $key ? ModelAccessor::get($value, $key) : ModelAccessor::get($value, $this->parent->getKeyName());
76 76
         }, $models)));
77 77
     }
@@ -120,7 +120,7 @@  discard block
 block discarded – undo
120 120
             return $models;
121 121
         }
122 122
 
123
-        return array_combine(array_map(function ($model) {
123
+        return array_combine(array_map(function($model) {
124 124
             return (new $model)->getTable();
125 125
         }, $models), $models);
126 126
     }
Please login to merge, or discard this patch.