mirror of
https://github.com/LemmyNet/lemmy.git
synced 2024-11-12 15:34:00 +00:00
Remove form_id params (#3812)
This commit is contained in:
parent
da031a4ce2
commit
2bb24c2859
10 changed files with 1 additions and 15 deletions
|
@ -52,6 +52,5 @@ pub async fn distinguish_comment(
|
|||
Ok(Json(CommentResponse {
|
||||
comment_view,
|
||||
recipient_ids: Vec::new(),
|
||||
form_id: None,
|
||||
}))
|
||||
}
|
||||
|
|
|
@ -89,7 +89,6 @@ pub async fn like_comment(
|
|||
context.deref(),
|
||||
comment_id,
|
||||
Some(local_user_view),
|
||||
None,
|
||||
recipient_ids,
|
||||
)
|
||||
.await?,
|
||||
|
|
|
@ -40,6 +40,5 @@ pub async fn save_comment(
|
|||
Ok(Json(CommentResponse {
|
||||
comment_view,
|
||||
recipient_ids: Vec::new(),
|
||||
form_id: None,
|
||||
}))
|
||||
}
|
||||
|
|
|
@ -26,7 +26,6 @@ pub async fn build_comment_response(
|
|||
context: &LemmyContext,
|
||||
comment_id: CommentId,
|
||||
local_user_view: Option<LocalUserView>,
|
||||
form_id: Option<String>,
|
||||
recipient_ids: Vec<LocalUserId>,
|
||||
) -> Result<CommentResponse, LemmyError> {
|
||||
let person_id = local_user_view.map(|l| l.person.id);
|
||||
|
@ -34,7 +33,6 @@ pub async fn build_comment_response(
|
|||
Ok(CommentResponse {
|
||||
comment_view,
|
||||
recipient_ids,
|
||||
form_id,
|
||||
})
|
||||
}
|
||||
|
||||
|
|
|
@ -20,8 +20,6 @@ pub struct CreateComment {
|
|||
pub post_id: PostId,
|
||||
pub parent_id: Option<CommentId>,
|
||||
pub language_id: Option<LanguageId>,
|
||||
/// An optional front-end ID, to help UIs determine where the comment should go.
|
||||
pub form_id: Option<String>,
|
||||
pub auth: Sensitive<String>,
|
||||
}
|
||||
|
||||
|
@ -44,7 +42,6 @@ pub struct EditComment {
|
|||
pub comment_id: CommentId,
|
||||
pub content: Option<String>,
|
||||
pub language_id: Option<LanguageId>,
|
||||
pub form_id: Option<String>,
|
||||
pub auth: Sensitive<String>,
|
||||
}
|
||||
|
||||
|
@ -100,8 +97,6 @@ pub struct SaveComment {
|
|||
pub struct CommentResponse {
|
||||
pub comment_view: CommentView,
|
||||
pub recipient_ids: Vec<LocalUserId>,
|
||||
/// An optional front end ID, to tell which is coming back
|
||||
pub form_id: Option<String>,
|
||||
}
|
||||
|
||||
#[derive(Debug, Serialize, Deserialize, Clone, Default)]
|
||||
|
|
|
@ -198,7 +198,6 @@ pub async fn create_comment(
|
|||
&context,
|
||||
inserted_comment.id,
|
||||
Some(local_user_view),
|
||||
data.form_id.clone(),
|
||||
recipient_ids,
|
||||
)
|
||||
.await?,
|
||||
|
|
|
@ -82,7 +82,6 @@ pub async fn delete_comment(
|
|||
&context,
|
||||
updated_comment_id,
|
||||
Some(local_user_view),
|
||||
None,
|
||||
recipient_ids,
|
||||
)
|
||||
.await?,
|
||||
|
|
|
@ -19,6 +19,6 @@ pub async fn get_comment(
|
|||
check_private_instance(&local_user_view, &local_site)?;
|
||||
|
||||
Ok(Json(
|
||||
build_comment_response(&context, data.id, local_user_view, None, vec![]).await?,
|
||||
build_comment_response(&context, data.id, local_user_view, vec![]).await?,
|
||||
))
|
||||
}
|
||||
|
|
|
@ -91,7 +91,6 @@ pub async fn remove_comment(
|
|||
&context,
|
||||
updated_comment_id,
|
||||
Some(local_user_view),
|
||||
None,
|
||||
recipient_ids,
|
||||
)
|
||||
.await?,
|
||||
|
|
|
@ -104,7 +104,6 @@ pub async fn update_comment(
|
|||
&context,
|
||||
updated_comment.id,
|
||||
Some(local_user_view),
|
||||
data.form_id.clone(),
|
||||
recipient_ids,
|
||||
)
|
||||
.await?,
|
||||
|
|
Loading…
Reference in a new issue