From 1a0ed716f7ec8e873966566cde50af2630203cb8 Mon Sep 17 00:00:00 2001 From: Tom Hughes Date: Fri, 29 Jun 2018 11:46:54 +0100 Subject: [PATCH] Convert some URLs to https --- lib/nominatim.rb | 2 +- lib/osm.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/nominatim.rb b/lib/nominatim.rb index 97d158cfd..ffa86d93f 100644 --- a/lib/nominatim.rb +++ b/lib/nominatim.rb @@ -6,7 +6,7 @@ module Nominatim language ||= http_accept_language.user_preferred_languages.join(",") Rails.cache.fetch "/nominatim/location/#{lat}/#{lon}/#{zoom}/#{language}" do - url = "http://nominatim.openstreetmap.org/reverse?lat=#{lat}&lon=#{lon}&zoom=#{zoom}&accept-language=#{language}" + url = "https://nominatim.openstreetmap.org/reverse?lat=#{lat}&lon=#{lon}&zoom=#{zoom}&accept-language=#{language}" begin response = OSM::Timer.timeout(4) do diff --git a/lib/osm.rb b/lib/osm.rb index 71e12534f..841cce17b 100644 --- a/lib/osm.rb +++ b/lib/osm.rb @@ -510,7 +510,7 @@ module OSM if ipinfo country = ipinfo.country_code2 else - country = http_client.get("http://api.hostip.info/country.php?ip=#{ip_address}").body + country = http_client.get("https://api.hostip.info/country.php?ip=#{ip_address}").body country = "GB" if country == "UK" end -- 2.39.5