Commit 5045d096 authored by Brian Tiger Chow's avatar Brian Tiger Chow Committed by Jeromy

style(bitswap) name -> loop

eh?

License: MIT
Signed-off-by: default avatarBrian Tiger Chow <brian@perfmode.com>
parent 499aa2c3
...@@ -44,7 +44,7 @@ func New(ctx context.Context, p peer.Peer, network bsnet.BitSwapNetwork, routing ...@@ -44,7 +44,7 @@ func New(ctx context.Context, p peer.Peer, network bsnet.BitSwapNetwork, routing
batchRequests: make(chan []u.Key, 32), batchRequests: make(chan []u.Key, 32),
} }
network.SetDelegate(bs) network.SetDelegate(bs)
go bs.run(ctx) go bs.loop(ctx)
return bs return bs
} }
...@@ -163,7 +163,7 @@ func (bs *bitswap) sendWantListTo(ctx context.Context, peers <-chan peer.Peer) e ...@@ -163,7 +163,7 @@ func (bs *bitswap) sendWantListTo(ctx context.Context, peers <-chan peer.Peer) e
} }
// TODO ensure only one active request per key // TODO ensure only one active request per key
func (bs *bitswap) run(ctx context.Context) { func (bs *bitswap) loop(ctx context.Context) {
// Every so often, we should resend out our current want list // Every so often, we should resend out our current want list
rebroadcastTime := time.Second * 5 rebroadcastTime := time.Second * 5
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment