From b6a0cb9e6f32d1e0b90217dbe777ff6aab4d2317 Mon Sep 17 00:00:00 2001 From: Corentin Cadiou Date: Sun, 24 Nov 2019 13:41:17 +0000 Subject: [PATCH] Move location URL to params --- bumblebee/modules/currency.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bumblebee/modules/currency.py b/bumblebee/modules/currency.py index 526821c..4e2e7c2 100644 --- a/bumblebee/modules/currency.py +++ b/bumblebee/modules/currency.py @@ -35,10 +35,11 @@ DEFAULT_SRC = "auto" DEFAULT_SRC_FALLBACK = "GBP" API_URL = "https://markets.ft.com/data/currencies/ajax/conversion?baseCurrency={}&comparison={}" +LOCATION_URL = "https://ipvigilante.com/" def get_local_country(): - r = requests.get('https://ipvigilante.com/') + r = requests.get(LOCATION_URL) location = r.json() return location['data']['country_name']