$fields->toArray()
Converts the fields collection to an array and also does that for every included field.
$fields->toArray(Closure|null $map = null): array
Parameters
| Name | Type | Default |
|---|---|---|
| $map | Closureornull |
null
|
Return type
array
This method modifies the existing $fields object it is applied to and returns it again.