From 84e5a4ae93eed6397a6cbf6091a0f5b3eacc78e2 Mon Sep 17 00:00:00 2001 From: Paul Buetow Date: Tue, 20 Jun 2023 02:06:22 +0300 Subject: add expiry log --- internal/config/config.go | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'internal/config') diff --git a/internal/config/config.go b/internal/config/config.go index ff8d452..ec4ea67 100644 --- a/internal/config/config.go +++ b/internal/config/config.go @@ -83,7 +83,8 @@ func (conf Config) NodeNumber(node string) int { return nodeNumber } - log.Println("config:", fmt.Errorf("node %s not found - it will affect it's score!", node)) + log.Println("config:", + fmt.Errorf("node %s not found - it will affect it's score!", node)) return 0 } @@ -99,7 +100,9 @@ func (conf Config) IsNode(remoteAddr string) bool { return false } -func (conf Config) IsNodeWithLookup(remoteAddr string, lookupIP func(string) ([]net.IP, error)) bool { +func (conf Config) IsNodeWithLookup(remoteAddr string, + lookupIP func(string) ([]net.IP, error)) bool { + remoteAddr = utils.StripPort(remoteAddr) for _, node := range conf.Nodes { -- cgit v1.2.3