@@ -52,7 +52,7 @@ discard block |
||
52 | 52 | if (static::$constraints) { |
53 | 53 | $column = $this->andSelf ? $this->parent->getLocalKeyName() : $this->parent->getParentKeyName(); |
54 | 54 | |
55 | - $constraint = function (Builder $query) use ($column) { |
|
55 | + $constraint = function(Builder $query) use ($column) { |
|
56 | 56 | $query->where( |
57 | 57 | $column, |
58 | 58 | '=', |
@@ -78,7 +78,7 @@ discard block |
||
78 | 78 | |
79 | 79 | $keys = $this->getKeys($models, $localKey); |
80 | 80 | |
81 | - $constraint = function (Builder $query) use ($keys, $localKey, $models, $whereIn) { |
|
81 | + $constraint = function(Builder $query) use ($keys, $localKey, $models, $whereIn) { |
|
82 | 82 | $query->$whereIn($localKey, $keys); |
83 | 83 | }; |
84 | 84 | |
@@ -178,7 +178,7 @@ discard block |
||
178 | 178 | ? $this->parent->getLocalKeyName() |
179 | 179 | : $this->parent->getParentKeyName(); |
180 | 180 | |
181 | - $constraint = function (Builder $query) use ($first, $table) { |
|
181 | + $constraint = function(Builder $query) use ($first, $table) { |
|
182 | 182 | $query->whereColumn( |
183 | 183 | $table.'.'.$first, |
184 | 184 | '=', |
@@ -213,7 +213,7 @@ discard block |
||
213 | 213 | |
214 | 214 | $query->withRecursiveExpression($name, $expression); |
215 | 215 | |
216 | - $query->withGlobalScope('HasManyOfDescendants', function (Builder $query) use ($name) { |
|
216 | + $query->withGlobalScope('HasManyOfDescendants', function(Builder $query) use ($name) { |
|
217 | 217 | $query->whereIn( |
218 | 218 | $this->foreignKey, |
219 | 219 | (new $this->parent)->setTable($name)->newQuery()->select($this->localKey) |
@@ -16,7 +16,7 @@ |
||
16 | 16 | */ |
17 | 17 | public function scopeTree(Builder $query, $maxDepth = null) |
18 | 18 | { |
19 | - $constraint = function (Builder $query) { |
|
19 | + $constraint = function(Builder $query) { |
|
20 | 20 | $query->isRoot(); |
21 | 21 | }; |
22 | 22 |