},
CommentId,
CommunityId,
+ DbUrl,
PersonId,
PostId,
};
listing_type: Option<ListingType>,
sort: Option<SortType>,
community_id: Option<CommunityId>,
- community_name: Option<String>,
+ community_actor_id: Option<DbUrl>,
post_id: Option<PostId>,
creator_id: Option<PersonId>,
recipient_id: Option<PersonId>,
listing_type: None,
sort: None,
community_id: None,
- community_name: None,
+ community_actor_id: None,
post_id: None,
creator_id: None,
recipient_id: None,
self
}
- pub fn community_name<T: MaybeOptional<String>>(mut self, community_name: T) -> Self {
- self.community_name = community_name.get_optional();
+ pub fn community_actor_id<T: MaybeOptional<DbUrl>>(mut self, community_actor_id: T) -> Self {
+ self.community_actor_id = community_actor_id.get_optional();
self
}
query = query.filter(post::community_id.eq(community_id));
}
- if let Some(community_name) = self.community_name {
- query = query
- .filter(community::name.eq(community_name))
- .filter(comment::local.eq(true));
+ if let Some(community_actor_id) = self.community_actor_id {
+ query = query.filter(community::actor_id.eq(community_actor_id))
}
if let Some(post_id) = self.post_id {