getRelatedPostsQuery method
- String id
Disapproves a post with the given id.
Implementation
Query<PostModel> getRelatedPostsQuery(String id) => instance
.collection('posts')
.where('approved', isEqualTo: true)
.where('event', isEqualTo: id)
.orderBy('postDate', descending: true)
.withConverter(
fromFirestore: (snapshot, _) =>
PostModel.fromJsonAndId(snapshot.data()!, snapshot.id),
toFirestore: (_, __) => {},
);