Merge pull request #1412 from LemmyNet/fix_search_communities_subscribed

Fixing community search not using auth. Fixes #1411
This commit is contained in:
Nutomic 2021-02-05 16:33:06 +00:00 committed by GitHub
commit d09df9c02b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -405,6 +405,7 @@ impl Perform for Search {
CommunityQueryBuilder::create(conn) CommunityQueryBuilder::create(conn)
.sort(&sort) .sort(&sort)
.search_term(q) .search_term(q)
.my_user_id(user_id)
.page(page) .page(page)
.limit(limit) .limit(limit)
.list() .list()
@ -458,6 +459,7 @@ impl Perform for Search {
CommunityQueryBuilder::create(conn) CommunityQueryBuilder::create(conn)
.sort(&sort) .sort(&sort)
.search_term(q) .search_term(q)
.my_user_id(user_id)
.page(page) .page(page)
.limit(limit) .limit(limit)
.list() .list()
@ -482,6 +484,7 @@ impl Perform for Search {
PostQueryBuilder::create(conn) PostQueryBuilder::create(conn)
.sort(&sort) .sort(&sort)
.show_nsfw(true) .show_nsfw(true)
.my_user_id(user_id)
.community_id(community_id) .community_id(community_id)
.community_name(community_name) .community_name(community_name)
.url_search(q) .url_search(q)