Commit 1838cf95 authored by Romain Bignon's avatar Romain Bignon

fix ipinfodb when no coordinates are given from web server

parent cfd18d98
......@@ -78,10 +78,7 @@ class IpinfodbBackend(BaseBackend, ICapGeolocIp): = float(tab['Latitude'])
iploc.lg = float(tab['Longitude'])
except ValueError:
if len(tab['Latitude']) == 0 or len(tab['Longitude']) == 0:
pass = tab['hostname']
iploc.tld = tab['hostname'].split('.')[-1]
#iploc.isp = 'NA'
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment