Fix: /force-update reload-Hänger + Cooldown persistent, SW by-v1106

User-Report: 'Leckerlis'-Screen verschwindet nicht mehr.

Bug: Vorige Version nutzte 'await Promise.all([sw-unregister,
caches.delete])' VOR dem Reload. Auf iOS-PWA können diese Promises
gelegentlich nie resolven → Reload kommt nie.

Fix /force-update:
- Cleanup-Tasks fire-and-forget (kein await, kein Promise.all)
- Sofort-Reload nach 150ms (kein await-Block)
- Fallback 1: Nach 3s erscheint 'App neu starten'-Button für
  manuellen Tap
- Fallback 2: Nach 6s automatisch location.href mit ?hard=1

Fix app.js Cooldown:
- localStorage statt sessionStorage — überlebt PWA-App-Close
- 10 Min statt 5 Min Cooldown (großzügiger Spielraum bei
  Update-Wellen)
This commit is contained in:
rene 2026-05-27 08:02:54 +02:00
parent b0ae71ba69
commit c8ef4939f1
6 changed files with 52 additions and 42 deletions

View file

@ -4,7 +4,7 @@
============================================================ */
// ← EINZIGE Stelle für die Version — STATIC_ASSETS und CACHE_VERSION leiten sich ab
const VER = '1105';
const VER = '1106';
const CACHE_VERSION = `by-v${VER}`;
const CACHE_STATIC = `${CACHE_VERSION}-static`;
const CACHE_TILES = 'ban-yaro-tiles-v1'; // bleibt über SW-Updates erhalten