Simplify redundant len check before range
ProprietaryRemove if len(s) > 0 { for ... range s } where the len check is redundant because range over nil/empty produces zero iterations.
org. openrewrite. golang. codequality. SimplifyRedundantLenBeforeRangemod run . --recipe= org. openrewrite. golang. codequality. SimplifyRedundantLenBeforeRangeInstall it once, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.