From 4d98d2026b67eae9e065041ca609e086853b8bbe Mon Sep 17 00:00:00 2001 From: Dan <619938+mallardduck@users.noreply.github.com> Date: Tue, 1 Mar 2022 09:49:30 -0500 Subject: [PATCH] Add union return to better typehint --- .../tables/src/Columns/Concerns/InteractsWithTableQuery.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/tables/src/Columns/Concerns/InteractsWithTableQuery.php b/packages/tables/src/Columns/Concerns/InteractsWithTableQuery.php index d83eced334..44487d9f11 100644 --- a/packages/tables/src/Columns/Concerns/InteractsWithTableQuery.php +++ b/packages/tables/src/Columns/Concerns/InteractsWithTableQuery.php @@ -120,7 +120,7 @@ trait InteractsWithTableQuery return $this->getRelationship($query)->getModel(); } - protected function getRelationship(Builder $query): Relation + protected function getRelationship(Builder $query): Relation|Builder { return $this->getQueryModel($query)->{$this->getRelationshipName()}(); }