- Some minor bugfixes done on the return type of searchRelation
This commit is contained in:
parent
902167c2ed
commit
497fe5547b
|
@ -37,7 +37,7 @@ class RelationBuilder
|
|||
}
|
||||
}
|
||||
|
||||
public function searchRelation(string $name) /* : object|EntityCollection|bool */
|
||||
public function searchRelation(string $name) : object|bool
|
||||
{
|
||||
# Resolve relations here if one is called
|
||||
if ( $this->entity->isLoaded() ) {
|
||||
|
@ -45,7 +45,7 @@ class RelationBuilder
|
|||
return $dataset;
|
||||
}
|
||||
|
||||
return $this->resolveRelation($name) ?: $this->resolveVirtual($name);
|
||||
return $this->resolveRelation($name) ?: $this->resolveVirtual($name) ?: false;
|
||||
}
|
||||
else {
|
||||
if ( $relation = $this->resolver->searchFieldAnnotation($name, new Relation() ) ) {
|
||||
|
|
Loading…
Reference in New Issue