改名
This commit is contained in:
+2
-1
@@ -148,11 +148,12 @@ class Collection extends AbstractCollection
|
||||
public function toArray(): array
|
||||
{
|
||||
$array = [];
|
||||
/** @var Model $value */
|
||||
foreach ($this as $value) {
|
||||
if (!is_object($value)) {
|
||||
continue;
|
||||
}
|
||||
$array[] = $value->toArray();
|
||||
$array[] = $value->setWith($this->query->with)->toArray();
|
||||
}
|
||||
$this->_item = [];
|
||||
return $array;
|
||||
|
||||
Reference in New Issue
Block a user