From 5aaa6da2388e2df5fe3746cf75a4c0d8fce25eb1 Mon Sep 17 00:00:00 2001 From: Matthias Wirth Date: Thu, 2 Oct 2025 15:21:24 +0000 Subject: [PATCH] adsb.im route API: use http when site runs via http this saves adsb.im some server cost thanks for providing the service --- html/script.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/html/script.js b/html/script.js index 4ba0245..3d11f76 100644 --- a/html/script.js +++ b/html/script.js @@ -1644,6 +1644,10 @@ jQuery('#selected_altitude_geom1') }); if (routeApiUrl) { + if (location.protocol == 'http:' && routeApiUrl == "https://adsb.im/api/0/routeset") { + // adsb.im API provider kindly asks that tar1090 uses http for the route API if possible + routeApiUrl = "http://adsb.im/api/0/routeset"; + } new Toggle({ key: "useRouteAPI", display: "Lookup route",