From 90b4bdcfc344a4aa3d6a48a9af3a096bf12fdecc Mon Sep 17 00:00:00 2001 From: xiaoqidun Date: Tue, 7 Jan 2025 16:15:28 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E4=BC=98=E5=8C=96=E6=9F=A5=E8=AF=A2):=20?= =?UTF-8?q?=E7=BB=9F=E4=B8=80=E5=B1=80=E5=9F=9F=E7=BD=91IP=E5=9C=B0?= =?UTF-8?q?=E5=9D=80=E7=9A=84ISP=E5=AD=97=E6=AE=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- qqwry.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/qqwry.go b/qqwry.go index cd734a0..fff5026 100644 --- a/qqwry.go +++ b/qqwry.go @@ -183,9 +183,6 @@ func QueryIPIpdb(ip string) (location *Location, err error) { return } location = SplitResult(ret[0], ret[1], ip) - if location.Country == "局域网" { - location.ISP = location.Country - } locationCache.Store(ip, location) return location, nil } @@ -231,5 +228,8 @@ func SplitResult(addr string, isp string, ipv4 string) (location *Location) { location.District = splitList[i] } } + if location.Country == "局域网" { + location.ISP = location.Country + } return }