Browse Source

修改get_district函数;

keiSenFront 2 years ago
parent
commit
6058fdcfd3
1 changed files with 1 additions and 1 deletions
  1. 1 1
      Controller/ShadowController.py

+ 1 - 1
Controller/ShadowController.py

@@ -183,7 +183,7 @@ def get_district(ip):
     else:
         ip_qs = IPQuery(ip)
         district = ip_qs.district
-        country_code = ip.country_id
+        country_code = ip_qs.country_id
         # ip地址信息存表
         IPAddr.objects.create(ip=ip, country_code=country_code, district=district)
     return district