Skip to content

Commit 66423b0

Browse files
committed
Support l5.2
1 parent f46043a commit 66423b0

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/QueryBuilder.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -856,7 +856,7 @@ public function fixTree($root = null)
856856

857857
$dictionary = $this->model
858858
->newNestedSetQuery()
859-
->when($root, function (self $query, $root) {
859+
->when($root, function (self $query) use ($root) {
860860
$query->whereDescendantOf($root);
861861
})
862862
->defaultOrder()
@@ -968,7 +968,7 @@ public function rebuildTree(array $data, $delete = false, $root = null)
968968
}
969969

970970
$existing = $this
971-
->when($root, function (self $query, $root) {
971+
->when($root, function (self $query) use ($root) {
972972
$query->whereDescendantOf($root);
973973
})
974974
->get()

0 commit comments

Comments
 (0)