fix: path is not defined in renderPage and HAVING clause SQL error

- router.js: route-announcer used bare `path` variable which is not in scope
  inside renderPage(); replaced with `route.path`
- dashboard.js: shoppingLists query used `HAVING open_count > 0` without GROUP BY;
  SQLite rejects this — replaced with a WHERE subquery

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Ulas Kalayci
2026-04-27 12:24:39 +02:00
parent 5d519129a9
commit 1821b7147a
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -343,7 +343,7 @@ async function renderPage(route, previousPath = null) {
// Route-Announcer: Screenreader über Seitenwechsel informieren (gezielt, nicht gesamter Inhalt)
const announcer = document.getElementById('route-announcer');
if (announcer) {
const pageLabel = navItems().find((n) => n.path === path)?.label ?? path;
const pageLabel = navItems().find((n) => n.path === route.path)?.label ?? route.path;
announcer.textContent = '';
setTimeout(() => { announcer.textContent = pageLabel; }, 50);
}