From 2bccd70a3f70b13f10a687aea234fdc43ef12a0c Mon Sep 17 00:00:00 2001 From: Tolmachev Igor Date: Thu, 25 Sep 2025 15:54:04 +0300 Subject: Rename /change methods to /update --- src/routers/account.rs | 18 +++++++++--------- src/routers/queue/manage.rs | 12 ++++++------ 2 files changed, 15 insertions(+), 15 deletions(-) (limited to 'src') diff --git a/src/routers/account.rs b/src/routers/account.rs index 1ae8c22..3159db6 100644 --- a/src/routers/account.rs +++ b/src/routers/account.rs @@ -205,7 +205,7 @@ async fn login( #[utoipa::path( put, - path = "/change/password", + path = "/update/password", tag = ACCOUNT, summary = "Change password", description = "Change your account password", @@ -219,7 +219,7 @@ async fn login( ), security(("auth" = [])) )] -async fn change_password( +async fn update_password( State(state): State, Auth(user): Auth, ApiJson(req): ApiJson, @@ -238,7 +238,7 @@ async fn change_password( #[utoipa::path( put, - path = "/change/username", + path = "/update/username", tag = ACCOUNT, summary = "Change username", description = "Change your account username", @@ -252,7 +252,7 @@ async fn change_password( ), security(("auth" = [])) )] -async fn change_username( +async fn update_username( State(state): State, Auth(user): Auth, ApiJson(req): ApiJson, @@ -273,7 +273,7 @@ async fn change_username( #[utoipa::path( put, - path = "/change/name", + path = "/update/name", tag = ACCOUNT, summary = "Change name", description = "Change your account first or last name", @@ -287,7 +287,7 @@ async fn change_username( ), security(("auth" = [])) )] -async fn change_name( +async fn update_name( State(state): State, Auth(user): Auth, ApiJson(req): ApiJson, @@ -340,8 +340,8 @@ pub fn router() -> OpenApiRouter { .routes(routes!(me)) .routes(routes!(register)) .routes(routes!(login)) - .routes(routes!(change_password)) - .routes(routes!(change_username)) - .routes(routes!(change_name)) + .routes(routes!(update_password)) + .routes(routes!(update_username)) + .routes(routes!(update_name)) .routes(routes!(delete)) } diff --git a/src/routers/queue/manage.rs b/src/routers/queue/manage.rs index f174bd5..f6587d1 100644 --- a/src/routers/queue/manage.rs +++ b/src/routers/queue/manage.rs @@ -130,7 +130,7 @@ async fn create( #[utoipa::path( put, - path = "/change/name", + path = "/update/name", tag = QUEUE, summary = "Change name", description = "Change queue name", @@ -144,7 +144,7 @@ async fn create( ), security(("auth" = [])), )] -async fn change_name( +async fn update_name( State(state): State, Auth(user): Auth, ApiJson(req): ApiJson, @@ -161,7 +161,7 @@ async fn change_name( #[utoipa::path( put, - path = "/change/owner", + path = "/update/owner", tag = QUEUE, summary = "Change owner", description = "Reassign queue ownership", @@ -175,7 +175,7 @@ async fn change_name( ), security(("auth" = [])), )] -async fn change_owner( +async fn update_owner( State(state): State, Auth(user): Auth, ApiJson(req): ApiJson, @@ -227,7 +227,7 @@ pub fn router() -> OpenApiRouter { OpenApiRouter::new() .routes(routes!(owned)) .routes(routes!(create)) - .routes(routes!(change_name)) - .routes(routes!(change_owner)) + .routes(routes!(update_name)) + .routes(routes!(update_owner)) .routes(routes!(delete)) } -- cgit v1.2.3