mirror of https://github.com/LemmyNet/lemmy.git
Fix missing local user from post queries. (#2447)
parent
c9f1407429
commit
9ce15ed071
|
@ -53,6 +53,7 @@ impl PerformCrud for GetPosts {
|
||||||
let mut posts = blocking(context.pool(), move |conn| {
|
let mut posts = blocking(context.pool(), move |conn| {
|
||||||
PostQuery::builder()
|
PostQuery::builder()
|
||||||
.conn(conn)
|
.conn(conn)
|
||||||
|
.local_user(local_user_view.map(|l| l.local_user).as_ref())
|
||||||
.listing_type(Some(listing_type))
|
.listing_type(Some(listing_type))
|
||||||
.sort(sort)
|
.sort(sort)
|
||||||
.community_id(community_id)
|
.community_id(community_id)
|
||||||
|
|
|
@ -68,9 +68,9 @@ impl PerformCrud for GetPersonDetails {
|
||||||
let posts = blocking(context.pool(), move |conn| {
|
let posts = blocking(context.pool(), move |conn| {
|
||||||
let posts_query = PostQuery::builder()
|
let posts_query = PostQuery::builder()
|
||||||
.conn(conn)
|
.conn(conn)
|
||||||
.local_user(local_user.as_ref())
|
|
||||||
.sort(sort)
|
.sort(sort)
|
||||||
.saved_only(saved_only)
|
.saved_only(saved_only)
|
||||||
|
.local_user(local_user.as_ref())
|
||||||
.community_id(community_id)
|
.community_id(community_id)
|
||||||
.page(page)
|
.page(page)
|
||||||
.limit(limit);
|
.limit(limit);
|
||||||
|
|
Loading…
Reference in New Issue