From f7a9d83545b832eae3cf06de4971e3751c50fd7e Mon Sep 17 00:00:00 2001 From: Dmitriy Ryajov Date: Mon, 15 Mar 2021 15:29:05 -0600 Subject: [PATCH] add mounted protos to identify message (#546) --- libp2p/switch.nim | 1 + 1 file changed, 1 insertion(+) diff --git a/libp2p/switch.nim b/libp2p/switch.nim index 19ce0d29f..a947e0708 100644 --- a/libp2p/switch.nim +++ b/libp2p/switch.nim @@ -288,6 +288,7 @@ proc mount*[T: LPProtocol](s: Switch, proto: T, matcher: Matcher = nil) {.gcsafe "Protocol has to define a codec string") s.ms.addHandler(proto.codecs, proto, matcher) + s.peerInfo.protocols.add(proto.codec) proc upgradeMonitor(conn: Connection, upgrades: AsyncSemaphore) {.async.} = ## monitor connection for upgrades