Merge pull request #4 from christophermluna/patch-1

Update API endpoint for GeoIP web services
This commit is contained in:
Vincent Bernat 2023-08-28 21:52:35 +02:00 committed by GitHub
commit 0d4680d9aa
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -18,7 +18,7 @@ def get_location():
"""Return current location as latitude/longitude tuple."""
logger.debug("query MaxMind for location")
r = requests.get(
"https://www.maxmind.com/geoip/v2.1/city/me",
"https://geoip.maxmind.com/geoip/v2.1/city/me",
headers={"referer": "https://www.maxmind.com/en/locate-my-ip-address"},
timeout=10,
)