Skip to content

Commit

Permalink
test something
Browse files Browse the repository at this point in the history
  • Loading branch information
wiedehopf committed Jan 24, 2021
1 parent f02cb5c commit 0dac376
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions html/script.js
Original file line number Diff line number Diff line change
Expand Up @@ -330,8 +330,14 @@ function fetchData(options) {

let suffix = binCraft ? '.binCraft' : '.json'
let mid = (binCraft && onlyMilitary) ? 'Mil_' : '_';
for (let i in indexes) {
ac_url.push('data/globe' + mid + indexes[i].toString().padStart(4, '0') + suffix);
if (adsbexchange) {
for (let i in indexes) {
ac_url.push('https://globe-data.adsbexchange.com/data/globe' + mid + indexes[i].toString().padStart(4, '0') + suffix);
}
} else {
for (let i in indexes) {
ac_url.push('data/globe' + mid + indexes[i].toString().padStart(4, '0') + suffix);
}
}
}
} else {
Expand All @@ -358,6 +364,7 @@ function fetchData(options) {
url: ac_url[i], method: 'GET',
xhr: function() { return xhrOverride; },
timeout: 5000,
withCredentials: true,
});
} else {
req = $.ajax({ url: ac_url[i], dataType: 'json' });
Expand Down

0 comments on commit 0dac376

Please sign in to comment.