Commit fc8168f6 authored by Brian Tiger Chow's avatar Brian Tiger Chow

fix(net) pass contexts to dial peer

parent 54b7ba45
......@@ -68,7 +68,7 @@ func (adapter *impl) HandleMessage(
}
func (adapter *impl) DialPeer(ctx context.Context, p peer.Peer) error {
return adapter.net.DialPeer(p)
return adapter.net.DialPeer(ctx, p)
}
func (adapter *impl) SendMessage(
......
......@@ -163,7 +163,7 @@ func (nc *networkClient) SendRequest(
return nc.network.SendRequest(ctx, nc.local, to, message)
}
func (nc *networkClient) DialPeer(p peer.Peer) error {
func (nc *networkClient) DialPeer(ctx context.Context, p peer.Peer) error {
// no need to do anything because dialing isn't a thing in this test net.
if !nc.network.HasPeer(p) {
return fmt.Errorf("Peer not in network: %s", p)
......
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