X-Git-Url: http://these/git/?a=blobdiff_plain;f=crates%2Fapi%2Fsrc%2Fcomment%2Fsave.rs;h=7161c8e9cdea8c3bca9f34653a62017a15e104a7;hb=1d38aad9d3d51ef606074d5b49a8030c49dd0e9e;hp=42c91bf05fbf6e336b5adf40d16d9dc5948b9b82;hpb=73492af4b09448684ffde3d55454434ec3ed490b;p=lemmy.git diff --git a/crates/api/src/comment/save.rs b/crates/api/src/comment/save.rs index 42c91bf0..7161c8e9 100644 --- a/crates/api/src/comment/save.rs +++ b/crates/api/src/comment/save.rs @@ -27,18 +27,18 @@ impl Perform for SaveComment { }; if data.save { - CommentSaved::save(context.pool(), &comment_saved_form) + CommentSaved::save(&mut context.pool(), &comment_saved_form) .await .with_lemmy_type(LemmyErrorType::CouldntSaveComment)?; } else { - CommentSaved::unsave(context.pool(), &comment_saved_form) + CommentSaved::unsave(&mut context.pool(), &comment_saved_form) .await .with_lemmy_type(LemmyErrorType::CouldntSaveComment)?; } let comment_id = data.comment_id; let person_id = local_user_view.person.id; - let comment_view = CommentView::read(context.pool(), comment_id, Some(person_id)).await?; + let comment_view = CommentView::read(&mut context.pool(), comment_id, Some(person_id)).await?; Ok(CommentResponse { comment_view,