geocode via internal /api/geo/autocomplete instead of geopf
Publish To Prod / deploy_and_publish (push) Successful in 1m7s

This commit is contained in:
Arnaud Delcasse
2026-06-08 13:58:52 +02:00
parent 89a0c490a8
commit a856209cc3
@@ -179,7 +179,7 @@
} }
try { try {
const response = await fetch(`https://data.geopf.fr/geocodage/search/?q=${encodeURIComponent(fieldData.input)}&limit=5`); const response = await fetch(`/api/geo/autocomplete?text=${encodeURIComponent(fieldData.input)}`);
const json = await response.json(); const json = await response.json();
fieldData.results = json.features || []; fieldData.results = json.features || [];
fieldData.showResults = fieldData.results.length > 0; fieldData.showResults = fieldData.results.length > 0;