add muxer type to json output
License: MIT Signed-off-by: Jeromy <why@ipfs.io>
Jeromy committed
Nov 4, 2016 at 11:43 UTC
795b3cc4c74560c43e14bb6fa6dfcabb2c875b2c
1 file changed
+6
core/commands/swarm.go
+6
@@ -88,6 +88,11 @@ var swarmPeersCmd = &cmds.Command{
88
Peer: pid.Pretty(),
89
}
90
91
+ swcon, ok := c.(*swarm.Conn)
92
+ if ok {
93
+ ci.Muxer = fmt.Sprintf("%T", swcon.StreamConn().Conn())
94
+ }
95
+
96
if verbose || latency {
97
ci.Latency = n.Peerstore.LatencyEWMA(pid).String()
98
}
@@ -147,6 +152,7 @@ type connInfo struct {
152
Addr string
153
Peer string
154
Latency string
155
+ Muxer string
156
Streams []streamInfo
157
}
158