Completed
Push — master ( d924ae...e049de )
by Jonas
04:49
created
src/Eloquent/HasRecursiveRelationships.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -269,7 +269,7 @@
 block discarded – undo
269 269
      */
270 270
     public function scopeTree(Builder $query)
271 271
     {
272
-        $constraint = function (Builder $query) {
272
+        $constraint = function(Builder $query) {
273 273
             $query->isRoot();
274 274
         };
275 275
         
Please login to merge, or discard this patch.
src/Eloquent/Relations/Descendants.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -21,7 +21,7 @@  discard block
 block discarded – undo
21 21
     public function addConstraints()
22 22
     {
23 23
         if (static::$constraints) {
24
-            $constraint = function (Builder $query) {
24
+            $constraint = function(Builder $query) {
25 25
                 if ($this->andSelf) {
26 26
                     $query->where($this->getQualifiedParentKeyName(), '=', $this->getParentKey());
27 27
                 } else {
@@ -46,7 +46,7 @@  discard block
 block discarded – undo
46 46
 
47 47
         $keys = $this->getKeys($models, $this->localKey);
48 48
 
49
-        $constraint = function (Builder $query) use ($models, $column, $keys) {
49
+        $constraint = function(Builder $query) use ($models, $column, $keys) {
50 50
             $query->whereIn($column, $keys);
51 51
         };
52 52
 
@@ -94,7 +94,7 @@  discard block
 block discarded – undo
94 94
 
95 95
         $foreignKey = $this->getForeignKeyName();
96 96
 
97
-        return $results->mapToDictionary(function (Model $result) use ($dictionary, $foreignKey) {
97
+        return $results->mapToDictionary(function(Model $result) use ($dictionary, $foreignKey) {
98 98
             if ($result->hasNestedPath()) {
99 99
                 $key = $dictionary[$result->getFirstPathSegment()]->{$foreignKey};
100 100
             } else {
@@ -123,7 +123,7 @@  discard block
 block discarded – undo
123 123
             ? $query->getQuery()->from.'.'.$this->localKey
124 124
             : $this->foreignKey;
125 125
 
126
-        $constraint = function (Builder $query) use ($first) {
126
+        $constraint = function(Builder $query) use ($first) {
127 127
             $query->whereColumn(
128 128
                 $first,
129 129
                 '=',
@@ -154,7 +154,7 @@  discard block
 block discarded – undo
154 154
             ? $table.'.'.$this->localKey
155 155
             : $table.'.'.$this->getForeignKeyName();
156 156
 
157
-        $constraint = function (Builder $query) use ($first) {
157
+        $constraint = function(Builder $query) use ($first) {
158 158
             $query->whereColumn(
159 159
                 $first,
160 160
                 '=',
Please login to merge, or discard this patch.
src/Eloquent/Relations/IsRecursiveRelation.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -40,7 +40,7 @@
 block discarded – undo
40 40
      */
41 41
     protected function buildDictionary(Collection $results)
42 42
     {
43
-        return $results->mapToDictionary(function (Model $result) {
43
+        return $results->mapToDictionary(function(Model $result) {
44 44
             return [$result->getFirstPathSegment() => $result];
45 45
         })->all();
46 46
     }
Please login to merge, or discard this patch.
src/Eloquent/Relations/Siblings.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -127,9 +127,9 @@  discard block
 block discarded – undo
127 127
         $second = $parentQuery->qualifyColumn($this->localKey);
128 128
 
129 129
         $query->select($columns)
130
-            ->where(function (Builder $query) use ($first, $second) {
130
+            ->where(function(Builder $query) use ($first, $second) {
131 131
                 $query->whereColumn($first, '=', $second)
132
-                    ->orWhere(function (Builder $query) use ($first, $second) {
132
+                    ->orWhere(function(Builder $query) use ($first, $second) {
133 133
                         $query->whereNull($first)->whereNull($second);
134 134
                     });
135 135
             });
@@ -165,9 +165,9 @@  discard block
 block discarded – undo
165 165
         $second = $this->getQualifiedParentKeyName();
166 166
 
167 167
         $query->select($columns)
168
-            ->where(function (Builder $query) use ($first, $second) {
168
+            ->where(function(Builder $query) use ($first, $second) {
169 169
                 $query->whereColumn($first, '=', $second)
170
-                    ->orWhere(function (Builder $query) use ($first, $second) {
170
+                    ->orWhere(function(Builder $query) use ($first, $second) {
171 171
                         $query->whereNull($first)->whereNull($second);
172 172
                     });
173 173
             });
Please login to merge, or discard this patch.
src/Eloquent/Relations/Ancestors.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -18,7 +18,7 @@  discard block
 block discarded – undo
18 18
     public function addConstraints()
19 19
     {
20 20
         if (static::$constraints) {
21
-            $constraint = function (Builder $query) {
21
+            $constraint = function(Builder $query) {
22 22
                 $key = $this->andSelf ? $this->getParentKey() : $this->getForeignKey();
23 23
 
24 24
                 $query->where($this->getQualifiedParentKeyName(), '=', $key);
@@ -40,7 +40,7 @@  discard block
 block discarded – undo
40 40
 
41 41
         $keys = $this->getKeys($models, $key);
42 42
 
43
-        $constraint = function (Builder $query) use ($keys) {
43
+        $constraint = function(Builder $query) use ($keys) {
44 44
             $query->whereIn($this->getQualifiedParentKeyName(), $keys);
45 45
         };
46 46
 
@@ -58,7 +58,7 @@  discard block
 block discarded – undo
58 58
     {
59 59
         $keys = parent::getKeys($models, $key);
60 60
 
61
-        return array_filter($keys, function ($value) {
61
+        return array_filter($keys, function($value) {
62 62
             return !is_null($value);
63 63
         });
64 64
     }
@@ -118,7 +118,7 @@  discard block
 block discarded – undo
118 118
 
119 119
         $key = $this->andSelf ? $this->localKey : $this->getForeignKeyName();
120 120
 
121
-        $constraint = function (Builder $query) use ($key) {
121
+        $constraint = function(Builder $query) use ($key) {
122 122
             $query->whereColumn(
123 123
                 $query->getQuery()->from.'.'.$this->localKey,
124 124
                 '=',
@@ -147,7 +147,7 @@  discard block
 block discarded – undo
147 147
 
148 148
         $key = $this->andSelf ? $this->localKey : $this->getForeignKeyName();
149 149
 
150
-        $constraint = function (Builder $query) use ($table, $key) {
150
+        $constraint = function(Builder $query) use ($table, $key) {
151 151
             $query->whereColumn(
152 152
                 $table.'.'.$this->localKey,
153 153
                 '=',
Please login to merge, or discard this patch.