Filters a copy of the items in the collection.
public find ( callback $filter, array $options = [] ) : mixed | ||
$filter | callback | Callback to use for filtering. |
$options | array | The available options are: - `'collect'`: If `true`, the results will be returned wrapped in a new `Collection` object or subclass. Defaults to `true`. |
Результат | mixed | The filtered items. Will be an array unless `'collect'` is defined in the `$options` argument, then an instance of this class will be returned. |