From 6de0af0650b51db21ae5ba2a6acff54563582ae3 Mon Sep 17 00:00:00 2001 From: Leonard Lyubich Date: Wed, 16 Jun 2021 13:28:20 +0300 Subject: [PATCH] [#607] network: Use Equal method in IsLocalAddress function Signed-off-by: Leonard Lyubich --- pkg/network/address.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/network/address.go b/pkg/network/address.go index af4a11b0bb..214e1cd1a8 100644 --- a/pkg/network/address.go +++ b/pkg/network/address.go @@ -129,7 +129,7 @@ func multiaddrStringFromHostAddr(host string) (string, error) { // IsLocalAddress returns true if network endpoint from local address // source is equal to network endpoint of passed address. func IsLocalAddress(src LocalAddressSource, addr *Address) bool { - return src.LocalAddress().ma.Equal(addr.ma) + return src.LocalAddress().Equal(addr) } // HostAddrFromMultiaddr converts "/dns4/localhost/tcp/8080" to "localhost:8080".