Replace filter with filterAny / filterAll. The latter is a TODO.