Change cache lifetime for JS files to 1 day

- Update `nginx.prod.conf` to reduce JS file expiration from 1 year to 1
  day
- Clear `edh-round-counter-state` from `localStorage` on game load
- Bump version from 2.1.10 to 2.1.12
This commit is contained in:
2026-04-10 12:31:24 +02:00
parent 58def0c006
commit fe9adb97fa
3 changed files with 7 additions and 4 deletions

View File

@@ -77,7 +77,7 @@ http {
# Hashed JS files (cache-busted)
location ~* ^/js/.*\.(js|mjs)$ {
limit_req zone=static burst=50 nodelay;
expires 1y;
expires 1d;
add_header Cache-Control "public, immutable";
}
@@ -117,12 +117,12 @@ http {
# Error pages
error_page 404 /404.html;
error_page 500 502 503 504 /50x.html;
location = /404.html {
root /usr/share/nginx/html;
internal;
}
location = /50x.html {
root /usr/share/nginx/html;
internal;

View File

@@ -232,6 +232,9 @@ function gameManager() {
this.resetForm()
this.showLogForm = false
await this.reloadStats()
// Reset the round counter state
localStorage.removeItem('edh-round-counter-state')
} else {
const errorData = await response.json()
this.serverError = errorData.message || 'Failed to log game'

View File

@@ -1 +1 @@
2.1.10
2.1.12