fix: pin golangci-lint install to commit SHA (fixes #13)
All checks were successful
check / check (push) Successful in 1m31s
All checks were successful
check / check (push) Successful in 1m31s
- Fix Dockerfile: use correct v2 module path with commit SHA (github.com/golangci/golangci-lint/v2/cmd/golangci-lint@eabc2638...) - Add CGO_ENABLED=0 for alpine compatibility - Fix 35 lint issues found by golangci-lint v2.1.6: - Remove unused nolint directives, add nolintlint where needed - Pre-allocate migrations slice - Use t.Context() instead of context.Background() in tests - Fix blank lines between comments and exported functions in ui.go
This commit is contained in:
@@ -224,7 +224,7 @@ func (s *Handlers) HandleChannelMembers() http.HandlerFunc {
|
||||
|
||||
var chID int64
|
||||
|
||||
err := s.params.Database.GetDB().QueryRowContext( //nolint:gosec // parameterized query
|
||||
err := s.params.Database.GetDB().QueryRowContext( //nolint:gosec,nolintlint // parameterized query
|
||||
r.Context(),
|
||||
"SELECT id FROM channels WHERE name = ?",
|
||||
name,
|
||||
@@ -401,7 +401,7 @@ func (s *Handlers) sendChannelMsg(
|
||||
) {
|
||||
var chID int64
|
||||
|
||||
err := s.params.Database.GetDB().QueryRowContext( //nolint:gosec // parameterized query
|
||||
err := s.params.Database.GetDB().QueryRowContext( //nolint:gosec,nolintlint // parameterized query
|
||||
r.Context(),
|
||||
"SELECT id FROM channels WHERE name = ?",
|
||||
channel,
|
||||
@@ -535,7 +535,7 @@ func (s *Handlers) handlePart(
|
||||
|
||||
var chID int64
|
||||
|
||||
err := s.params.Database.GetDB().QueryRowContext( //nolint:gosec // parameterized query
|
||||
err := s.params.Database.GetDB().QueryRowContext( //nolint:gosec,nolintlint // parameterized query
|
||||
r.Context(),
|
||||
"SELECT id FROM channels WHERE name = ?",
|
||||
channel,
|
||||
@@ -717,7 +717,7 @@ func (s *Handlers) getChannelHistory(
|
||||
) {
|
||||
var chID int64
|
||||
|
||||
err := s.params.Database.GetDB().QueryRowContext( //nolint:gosec // parameterized query
|
||||
err := s.params.Database.GetDB().QueryRowContext( //nolint:gosec,nolintlint // parameterized query
|
||||
r.Context(),
|
||||
"SELECT id FROM channels WHERE name = ?",
|
||||
target,
|
||||
|
||||
Reference in New Issue
Block a user