adsb.im route API: use http when site runs via http

this saves adsb.im some server cost
thanks for providing the service
This commit is contained in:
Matthias Wirth
2025-10-02 15:21:24 +00:00
parent 32e86f3b20
commit 5aaa6da238

View File

@@ -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",