Skip to content

linter: whitespace, modernize, ineffassign, wastedassign#833

Open
mzihlmann wants to merge 4 commits into
mainfrom
lint-whitespace
Open

linter: whitespace, modernize, ineffassign, wastedassign#833
mzihlmann wants to merge 4 commits into
mainfrom
lint-whitespace

Conversation

@mzihlmann

@mzihlmann mzihlmann commented Jun 26, 2026

Copy link
Copy Markdown
Collaborator

Bundles four small, mechanical, easy-to-review linter cleanups carved from #539 (kept together since each is trivial):

  • whitespace: drop unnecessary leading/trailing blank lines in function bodies
  • modernize: strings.Split range loop becomes strings.SplitSeq
  • ineffassign / wastedassign: remove assignments overwritten before use (uid, gid := -1, -1, val = "", r := "" become plain var or are removed)

All behaviour-preserving and generated/derived from golangci-lint. The linters themselves are not enabled in the config here, that stays in #539.

@mzihlmann mzihlmann requested review from 0hlov3, BobDu, babs and nejch June 26, 2026 10:04
@mzihlmann mzihlmann changed the title linter: whitespace linter: whitespace, modernize, ineffassign, wastedassign Jun 26, 2026
This was referenced Jun 26, 2026
@codecov

codecov Bot commented Jun 26, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 50.00000% with 1 line in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
pkg/util/assert.go 0.00% 1 Missing ⚠️

📢 Thoughts on this report? Let us know!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant