From 06432644e571413ed77e423e346dd6d71822b8aa Mon Sep 17 00:00:00 2001 From: softdevee Date: Wed, 30 Sep 2020 10:03:32 +0300 Subject: [PATCH] Fix breaking change for morphto Breaking change in minor release https://github.com/laravel/framework/pull/34531 --- src/Jenssegers/Mongodb/Relations/MorphTo.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Jenssegers/Mongodb/Relations/MorphTo.php b/src/Jenssegers/Mongodb/Relations/MorphTo.php index 704c472..5938f9e 100644 --- a/src/Jenssegers/Mongodb/Relations/MorphTo.php +++ b/src/Jenssegers/Mongodb/Relations/MorphTo.php @@ -31,7 +31,7 @@ protected function getResultsByType($type) $query = $instance->newQuery(); - return $query->whereIn($key, $this->gatherKeysByType($type))->get(); + return $query->whereIn($key, $this->gatherKeysByType($type, $instance->getKeyType()))->get(); } /**