Skip to content

Commit

Permalink
style(internal/metrics): add nolint for gosec warning
Browse files Browse the repository at this point in the history
  • Loading branch information
nullswan committed Sep 12, 2024
1 parent 929c36f commit 8ddb153
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/metrics/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ func StartServer(log *slog.Logger, cancel context.CancelFunc, port uint32) {
http.Handle("/metrics", promhttp.Handler())

log.With("port", port).Info("Starting metrics server")
err := http.ListenAndServe(fmt.Sprintf(":%d", port), nil)
err := http.ListenAndServe(fmt.Sprintf(":%d", port), nil) // nolint:gosec
if err != nil {
log.With("error", err).Error("Failed to start metrics server")
cancel()
Expand Down

0 comments on commit 8ddb153

Please sign in to comment.