refactor: split monolithic handlers + testing into domain-grouped modules
Some checks failed
CI / Check / Test (push) Has been cancelled

handlers/api.rs (1706 LOC) + html.rs (1735 LOC) → 12 domain files:
auth, diary, movies, users, search, watchlist, goals, social,
integrations, helpers + existing import/webhook/wrapup/images/rss.

domain/testing.rs (1309 LOC) → testing/ module:
in_memory, fakes, noops, panics, wrapup.

Update README + architecture.mmd with goals feature.
This commit is contained in:
2026-06-08 23:59:23 +02:00
parent 988e15eac6
commit a7a11dde08
33 changed files with 5066 additions and 4891 deletions

View File

@@ -302,7 +302,7 @@ pub async fn get_user_wrapup_html(
};
let video_url = format!("/api/v1/wrapups/{}/video", record.id.value());
let ctx = super::html::build_page_context(&state, viewer, csrf.0).await;
let ctx = super::helpers::build_page_context(&state, viewer, csrf.0).await;
render_wrapup(&report, year, &ctx, Some(video_url))
}
@@ -338,6 +338,6 @@ pub async fn get_global_wrapup_html(
};
let video_url = format!("/api/v1/wrapups/{}/video", record.id.value());
let ctx = super::html::build_page_context(&state, viewer, csrf.0).await;
let ctx = super::helpers::build_page_context(&state, viewer, csrf.0).await;
render_wrapup(&report, year, &ctx, Some(video_url))
}