Skip to content

Commit

Permalink
Merge pull request #79 from mrd0ll4r/lint-fixes
Browse files Browse the repository at this point in the history
*: make linter happy
  • Loading branch information
mrd0ll4r authored Sep 16, 2024
2 parents de0daf9 + cb47465 commit 0563d95
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions metricplugin/bitswap_discovery_probe.go
Original file line number Diff line number Diff line change
Expand Up @@ -296,7 +296,7 @@ func (wt *BitswapDiscoveryProbe) broadcast(cids []cid.Cid, want bool, cancelAfte
workChan := make(chan peer.ID)
for i := 0; i < numGoroutines; i++ {
wg.Add(1)
go func(i int) {
go func() {
defer wg.Done()

// We allocate and reuse one message to save strain on the GC.
Expand All @@ -318,7 +318,7 @@ func (wt *BitswapDiscoveryProbe) broadcast(cids []cid.Cid, want bool, cancelAfte

sendBroadcastSinglePeer(want, sender, cids, msg, logger, peerID, resultsChan, cancelAfterSeconds, cancelAfter, &wg)
}
}(i)
}()
}

// Feed work into workers
Expand Down
2 changes: 1 addition & 1 deletion metricplugin/metric_export.go
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,7 @@ func tracerSetup() interface{} {
// Add lifecycle stuff to shut down cleanly.
// TODO I don't think this works.
lc.Append(fx.Hook{
OnStop: func(ctx context.Context) error {
OnStop: func(_ context.Context) error {
tracer.Shutdown()
return nil
},
Expand Down

0 comments on commit 0563d95

Please sign in to comment.