Passes the input to the output, but skips it if it is empty (PHP empty(): null, false, 0, '0', '', []).
Useful after an aggregator task to avoid processing empty results.
- Service:
CleverAge\ProcessBundle\Task\SkipEmptyTask
any
any: the input, unchanged, if it is not empty (the task is skipped otherwise)
This task has no option.
- Only continue when the merged result is not empty
# Task configuration level
merge:
service: '@CleverAge\ProcessBundle\Task\ArrayMergeTask'
outputs: [skip_if_empty]
skip_if_empty:
service: '@CleverAge\ProcessBundle\Task\SkipEmptyTask'
outputs: [next_task]