Find ?.let { it } no-ops

Proprietary

x?.let { it } is structurally equivalent to x — the lambda introduces a binding and immediately returns it without transforming. Drop the .let { it } call.

org.openrewrite.kotlin.idiom.FindLetItIdentity$KtRecipe
mod run . --recipe='org.openrewrite.kotlin.idiom.FindLetItIdentity$KtRecipe'

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