Merge identical branches

Proprietary

Merge consecutive if/else-if branches that have identical bodies by combining their conditions with ||.

OpenRewrite.Recipes.CSharp.CodeQuality.Simplification.MergeIdenticalBranches
mod run . --recipe=OpenRewrite.Recipes.CSharp.CodeQuality.Simplification.MergeIdenticalBranches

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