Use ListUtils.filter instead of mapping elements to null

MSAL

Replaces ListUtils.map(list, e -> condition ? null : e) and the equivalent block lambdas with ListUtils.filter(list, e -> !condition), which states the intent of removing elements directly.

org.openrewrite.java.recipes.ListUtilsFilterOverMapToNull
mod run . --recipe=org.openrewrite.java.recipes.ListUtilsFilterOverMapToNull

Install it once from Recipe actions, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.