diff --git a/src/public/scripts/geolocation.js b/src/public/scripts/geolocation.js index 26f2e1a..51096a6 100644 --- a/src/public/scripts/geolocation.js +++ b/src/public/scripts/geolocation.js @@ -38,7 +38,7 @@ function update(data) { dropdown.appendChild(listItem); }); - console.log(data); + // console.log(data); } function switchButton(clickedButton) { diff --git a/src/router/user.js b/src/router/user.js index 42134cd..740bc59 100644 --- a/src/router/user.js +++ b/src/router/user.js @@ -505,7 +505,7 @@ module.exports = (middleware, users, plans, assets) => { }); router.get("/exRates/:lat/:lon", async (req, res) => { if (!req.session.geoData.country) { - const response = await fetch(`https://maps.googleapis.com/maps/api/geocode/json?latlng=${req.params.lat},${req.params.lon}&result_type=country&key=${process.env.geolocation_api}`); + const response = await fetch(`https://maps.googleapis.com/maps/api/geocode/json?latlng=${req.params.lat},${req.params.lon}&result_type=country&key=${process.env.GEOLOCATION_API}`); const data = await response.json(); country = data.results[0].formatted_address;