This commit is contained in:
2021-01-26 17:08:56 +08:00
parent 0c249afb91
commit 8df208f177
+3
View File
@@ -292,6 +292,9 @@ class ActiveRecord extends BaseActiveRecord
return $data; return $data;
} }
$resolve = $this->{$data}(); $resolve = $this->{$data}();
if ($resolve instanceof HasBase) {
$resolve = $resolve->get();
}
if ($resolve instanceof Collection) { if ($resolve instanceof Collection) {
return $resolve->toArray(); return $resolve->toArray();
} }