feat(presentation): wire GET /users/{username}/follower-list and /following-list

This commit is contained in:
2026-05-14 15:34:33 +02:00
parent 6eba91e699
commit a2cc4fba21

View File

@@ -22,6 +22,8 @@ pub fn router(fed_config: &ApFederationConfig) -> Router<AppState> {
.route("/auth/register", post(auth::post_register)) .route("/auth/register", post(auth::post_register))
.route("/auth/login", post(auth::post_login)) .route("/auth/login", post(auth::post_login))
// users — static paths before parameterised // users — static paths before parameterised
.route("/users", get(users::get_users))
.route("/users/count", get(users::get_user_count))
.route("/users/me", get(users::get_me).patch(users::patch_profile)) .route("/users/me", get(users::get_me).patch(users::patch_profile))
.route("/users/me/top-friends", put(social::put_top_friends)) .route("/users/me/top-friends", put(social::put_top_friends))
.route("/users/{username}/top-friends", get(social::get_top_friends_handler)) .route("/users/{username}/top-friends", get(social::get_top_friends_handler))
@@ -56,7 +58,10 @@ pub fn router(fed_config: &ApFederationConfig) -> Router<AppState> {
.route("/feed", get(feed::home_feed)) .route("/feed", get(feed::home_feed))
.route("/feed/public", get(feed::public_feed)) .route("/feed/public", get(feed::public_feed))
.route("/search", get(feed::search_handler)) .route("/search", get(feed::search_handler))
.route("/users/{username}/follower-list", get(feed::get_followers_handler))
.route("/users/{username}/following-list", get(feed::get_following_handler))
.route("/users/{username}/thoughts", get(feed::user_thoughts_handler)) .route("/users/{username}/thoughts", get(feed::user_thoughts_handler))
.route("/tags/popular", get(feed::get_popular_tags))
.route("/tags/{name}", get(feed::tag_thoughts_handler)) .route("/tags/{name}", get(feed::tag_thoughts_handler))
// notifications // notifications
.route("/notifications", get(notifications::list_notifications)) .route("/notifications", get(notifications::list_notifications))