diff --git a/src/NovaBelongsToDepend.php b/src/NovaBelongsToDepend.php index 7603203..df8e39b 100644 --- a/src/NovaBelongsToDepend.php +++ b/src/NovaBelongsToDepend.php @@ -131,7 +131,9 @@ public function resolve($resource, $attribute = null) } parent::resolve($resource, $attribute); - $this->resourceParentClass = get_class(Nova::newResourceFromModel($resource)); + if (!$this->resourceParentClass) { + $this->resourceParentClass = get_class(Nova::newResourceFromModel($resource)); + } $foreign = $resource->{$this->attribute}(); $this->foreignKeyName = $foreign->getForeignKeyName();