$collection->filter($callback)

Filter the elements in the array by a callback function

  • $callback (function)
    the callback function
  • return ($collection)