public __get ( $prop ) : Lavary\Menu\Item | ||
return | Lavary\Menu\Item |
public function __get($prop)
{
if (property_exists($this, $prop)) {
return $this->{$prop};
}
return $this->whereNickname($prop)->first();
}