Items

Manually Filtering

To filter your items programatically via the title property (case insensitive):

$workflow->items()->filter('Bob');

With a custom property:

$workflow->items()->filter('Bob', 'subtitle');

You can also pass in a function or method as the first parameter to handle filtering yourself:

use Alfred\Workflows\Item;

$workflow->items()->filter(function(Item $item) {
    return $item->subtitle !== 'Louise';
});
Previous
Manually Sorting