From ce16ed90c37d63bc165b50d3ad73855c1db8cfba Mon Sep 17 00:00:00 2001 From: Tatiana Villa Date: Fri, 6 Feb 2026 10:27:35 +0100 Subject: [PATCH] Gestion de apis --- eltiempo/js/estadisticas.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/eltiempo/js/estadisticas.js b/eltiempo/js/estadisticas.js index ac5377b..b7ac134 100644 --- a/eltiempo/js/estadisticas.js +++ b/eltiempo/js/estadisticas.js @@ -39,7 +39,7 @@ async function loadStats() { async function loadStatsToday() { try { - const response = await fetch(API_URL_TODAY); + const response = await fetch(API_URL); if (!response.ok) throw new Error("Error cargando datos: " + response.status); const data = await response.json(); @@ -67,7 +67,7 @@ function renderLastData(data) { $("last-wind").textContent = last.viento_velocidad + " km/h"; $("last-sunrise").textContent = last.amanecer; $("last-sunset").textContent = last.anochecer; -} +} // ==================== // Estadísticas del mes seleccionado