From 30037bc5cb479fe1c9fda98c76bb39a41a85099f Mon Sep 17 00:00:00 2001
From: Daniel Arroyo
Date: Sun, 23 Aug 2026 12:49:24 -0400
Subject: [PATCH] fix: add ?v=5 cache-busting to all script tags
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
El error 'window.api.updateCharacterWeight is not a function' se daba
porque el browser tenía cacheada la versión vieja de api.js (que
tenía updateCharacterInventory en vez de updateCharacterWeight).
Agregar ?v=5 a los script src fuerza al browser a re-descargar el JS
cuando el URL cambia (con cada nueva versión bump n). Previene
errores 'is not a function' después de deploys que agregan/renombran
métodos.
Aplica a todos los archivos HTML que cargan JS estático.
---
.../templates/PageResource/calculadora.html | 12 ++++++------
.../templates/PageResource/changePassword.html | 8 ++++----
.../resources/templates/PageResource/historial.html | 10 +++++-----
.../resources/templates/PageResource/insumos.html | 8 ++++----
src/main/resources/templates/PageResource/login.html | 8 ++++----
.../resources/templates/PageResource/personajes.html | 8 ++++----
.../resources/templates/PageResource/register.html | 8 ++++----
.../resources/templates/PageResource/usuarios.html | 8 ++++----
.../resources/templates/PageResource/ventas.html | 8 ++++----
9 files changed, 39 insertions(+), 39 deletions(-)
diff --git a/src/main/resources/templates/PageResource/calculadora.html b/src/main/resources/templates/PageResource/calculadora.html
index 02169fc..5178594 100644
--- a/src/main/resources/templates/PageResource/calculadora.html
+++ b/src/main/resources/templates/PageResource/calculadora.html
@@ -975,12 +975,12 @@
-
-
-
-
-
-
+
+
+
+
+
+
-
-
-
+
+
+
+