Add gosimple linter (#23250)

#23249

Add gosimple linter to golangci-lint CI job.
This commit is contained in:
Victor Lyuboslavsky
2024-10-29 14:17:51 -05:00
committed by GitHub
parent 6f6ecf010d
commit e2d9a9016c
57 changed files with 115 additions and 162 deletions
@@ -61,9 +61,7 @@ func parseOptions(reader io.Reader) (any, error) {
kv[1] = strings.Trim(kv[1], `" `)
// Remove parenthetical note about an unset default
if strings.HasSuffix(kv[1], " (unset default)") {
kv[1] = kv[1][:len(kv[1])-len(" (unset default)")]
}
kv[1] = strings.TrimSuffix(kv[1], " (unset default)")
if lastKey == "rfm-reason" && kv[0] == "code" {
kv[0] = "rfm-reason-code"