blocking,
check_community_ban,
check_downvotes_enabled,
- check_person_block,
comment::*,
get_local_user_view_from_jwt,
};
)
.await?;
- check_person_block(
- local_user_view.person.id,
- orig_comment.get_recipient_id(),
- context.pool(),
- )
- .await?;
-
// Add parent user to recipients
let recipient_id = orig_comment.get_recipient_id();
if let Ok(local_recipient) = blocking(context.pool(), move |conn| {
check_community_ban,
check_community_deleted_or_removed,
check_downvotes_enabled,
- check_person_block,
get_local_user_view_from_jwt,
is_mod_or_admin,
mark_post_as_read,
check_community_ban(local_user_view.person.id, post.community_id, context.pool()).await?;
check_community_deleted_or_removed(post.community_id, context.pool()).await?;
- check_person_block(local_user_view.person.id, post.creator_id, context.pool()).await?;
-
let like_form = PostLikeForm {
post_id: data.post_id,
person_id: local_user_view.person.id,
#[allow(clippy::to_string_in_display)]
fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
// Use to_string here because Url.display is not useful for us
- write!(f, "{}", self.0.to_string())
+ write!(f, "{}", self.0)
}
}
let mut channel_builder = ChannelBuilder::default();
channel_builder
.namespaces(RSS_NAMESPACE.to_owned())
- .title(&format!(
- "{} - {}",
- site_view.site.name,
- listing_type.to_string()
- ))
+ .title(&format!("{} - {}", site_view.site.name, listing_type))
.link(context.settings().get_protocol_and_hostname())
.items(items);