diff --git a/config.js b/config.js index 350c804..d32fae5 100644 --- a/config.js +++ b/config.js @@ -62,6 +62,14 @@ window.CONFIG = { debug: 0, // 1 = debug panel + progress logs in the console // debug: 1 credits: false, // attribution line hidden + + // Optional same-origin Overpass proxy probe. The public Overpass mirrors + // work directly from the browser; keep this false unless the background + // nginx proxy is known to be reachable and you want cached same-origin calls. + overpass: { + useProxy: false, // true = probe /overpass/... and use it when available + // useProxy: true + }, // credits: false units: { temperature: 'C' }, // 'F' for Fahrenheit // units: { temperature: 'F' } diff --git a/vendor/clouds3d.js b/vendor/clouds3d.js index d94a81f..f7982e0 100644 --- a/vendor/clouds3d.js +++ b/vendor/clouds3d.js @@ -3199,6 +3199,7 @@ function opProbeProxy() { if (_opProxyChecked) return; _opProxyChecked = true; if (location.protocol === 'file:') return; + if (!(window.CONFIG && window.CONFIG.overpass && window.CONFIG.overpass.useProxy)) return; fetch(OP_PROXY[0], { method: 'POST', headers: { 'Content-Type': 'application/x-www-form-urlencoded' },