func MultiaddrProtocolsMatch(a, b ma.Multiaddr) bool {
	ap := a.Protocols()
	bp := b.Protocols()

	if len(ap) != len(bp) {
		return false
	}

	for i, api := range ap {
		if api.Code != bp[i].Code {
			return false
		}
	}

	return true
}
func MultiaddrProtocolsMatch(a, b ma.Multiaddr) bool {
	ap := a.Protocols()
	bp := b.Protocols()

	if len(ap) != len(bp) {
		return false
	}

	for i, api := range ap {
		if api.Code != bp[i].Code {
			return false
		}
	}

	return true
}
func MultiaddrProtocolsMatch ( a , b ma . Multiaddr ) bool { ap := a . Protocols ( ) bp := b . Protocols ( ) if len ( ap ) != len ( bp ) { return false } for i , api := range ap { if api . Code != bp [ i ] . Code { return false } } return true }
// MultiaddrProtocolsMatch returns whether two multiaddrs match in protocol stacks.
MultiaddrProtocolsMatch returns whether two multiaddrs match in protocol stacks .