diff --git a/bitswap.go b/bitswap.go index d016c65924a1ed20c55e7314355a57c6355d0da7..0a6a6f83e702557190765a6167b11119dd930e70 100644 --- a/bitswap.go +++ b/bitswap.go @@ -66,8 +66,8 @@ var rebroadcastDelay = delay.Fixed(time.Minute) // BitSwapNetwork. This function registers the returned instance as the network // delegate. // Runs until context is cancelled. -func New(parent context.Context, p peer.ID, network bsnet.BitSwapNetwork, - bstore blockstore.Blockstore, nice bool) exchange.Interface { +func New(parent context.Context, network bsnet.BitSwapNetwork, + bstore blockstore.Blockstore) exchange.Interface { // important to use provided parent context (since it may include important // loggable data). It's probably not a good idea to allow bitswap to be diff --git a/testutils.go b/testutils.go index 4df79c1b5550fc809877e12ba5fc609e6e394044..cbca2f8223076ca87eaf9b96a76c94e976bc6f4a 100644 --- a/testutils.go +++ b/testutils.go @@ -99,9 +99,7 @@ func MkSession(ctx context.Context, net tn.Network, p testutil.Identity) Instanc panic(err.Error()) // FIXME perhaps change signature and return error. } - const alwaysSendToPeer = true - - bs := New(ctx, p.ID(), adapter, bstore, alwaysSendToPeer).(*Bitswap) + bs := New(ctx, adapter, bstore).(*Bitswap) return Instance{ Peer: p.ID(),