Skip to content

Commit

Permalink
p2p: Fix "Unknown Channel" bug on CustomReactors (#6297)
Browse files Browse the repository at this point in the history
  • Loading branch information
tnasu committed Dec 23, 2021
1 parent b59f44d commit 4f22ffe
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion p2p/peer.go
Original file line number Diff line number Diff line change
Expand Up @@ -135,10 +135,15 @@ func newPeer(
onPeerError func(Peer, interface{}),
options ...PeerOption,
) *peer {
var channs = make([]byte, 0, len(chDescs))
for _, desc := range chDescs {
channs = append(channs, desc.ID)
}

p := &peer{
peerConn: pc,
nodeInfo: nodeInfo,
channels: nodeInfo.(DefaultNodeInfo).Channels, // TODO
channels: channs,
Data: cmap.NewCMap(),
metricsTicker: time.NewTicker(metricsTickerDuration),
metrics: NopMetrics(),
Expand Down

0 comments on commit 4f22ffe

Please sign in to comment.