From 513aabf579777fcf3e8b6b3770cc2e86485f64b9 Mon Sep 17 00:00:00 2001 From: Dennis Nemec Date: Wed, 2 Sep 2026 21:38:11 +0200 Subject: [PATCH] Keep 200 status for SPA fallback Co-Authored-By: Claude Fable 5.1 --- backend/crates/api/src/lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/crates/api/src/lib.rs b/backend/crates/api/src/lib.rs index f9aab7e..6eea443 100644 --- a/backend/crates/api/src/lib.rs +++ b/backend/crates/api/src/lib.rs @@ -63,7 +63,7 @@ impl AppState { pub fn build_app(state: AppState) -> Router { let index = format!("{}/index.html", state.cfg.frontend_dir); - let spa = ServeDir::new(&state.cfg.frontend_dir).not_found_service(ServeFile::new(index)); + let spa = ServeDir::new(&state.cfg.frontend_dir).fallback(ServeFile::new(index)); Router::new() .route("/healthz", get(healthz)) .route("/api/openapi.json", get(openapi::spec))