Skip to content

Commit

Permalink
Resolve error
Browse files Browse the repository at this point in the history
  • Loading branch information
staudenmeir committed Aug 29, 2024
1 parent f2d51a9 commit c5d65e0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/Eloquent/Relations/Siblings.php
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ public function addConstraints()
*/
public function addEagerConstraints(array $models)
{
/** @var array<int, int|string|null> $keys */
$keys = $this->getKeys($models, $this->localKey);

$this->query->where(
Expand Down
1 change: 1 addition & 0 deletions src/Eloquent/Relations/Traits/IsAncestorRelation.php
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ public function addEagerConstraints(array $models)
*/
protected function getKeys(array $models, $key = null)
{
/** @var array<int, int|string|null> $keys */
$keys = parent::getKeys($models, $key);

return array_filter($keys, function ($value) {
Expand Down

0 comments on commit c5d65e0

Please sign in to comment.