feat: redirect root path based on auth state #52

Merged
sneak merged 2 commits from feature/root-redirect-by-auth-state into main 2026-03-17 16:35:09 +01:00

2 Commits

Author SHA1 Message Date
clawbot
ff07022f1c chore: delete dead templates/index.html
All checks were successful
check / check (push) Successful in 1m3s
The template was removed from the template map and is no longer
rendered, but the file was still on disk and embedded via
//go:embed *.html. Remove it to complete the cleanup.
2026-03-17 05:06:13 -07:00
clawbot
9a0a6f88e3 feat: redirect root path based on auth state
All checks were successful
check / check (push) Successful in 1m53s
/ now checks for an authenticated session:
- Authenticated users → 303 redirect to /sources
- Unauthenticated users → 303 redirect to /pages/login

Removes the old index page template rendering and formatUptime
helper (now dead code). Adds tests for both redirect cases.
2026-03-17 04:58:20 -07:00