From: Dessalines Date: Fri, 5 Feb 2021 15:36:28 +0000 (-0500) Subject: Fixing community search not using auth. Fixes #1411 X-Git-Url: http://these/git/%7B%60%24%7BwebArchiveUrl%7D/%22%7B%7D/%22https:/nerdica.net/%7Biframely.url%7D?a=commitdiff_plain;h=4864f806569750b77adfa26bf68874cb49eac68c;p=lemmy.git Fixing community search not using auth. Fixes #1411 --- diff --git a/crates/api/src/site.rs b/crates/api/src/site.rs index 8fbb8f1c..96ce50ca 100644 --- a/crates/api/src/site.rs +++ b/crates/api/src/site.rs @@ -405,6 +405,7 @@ impl Perform for Search { CommunityQueryBuilder::create(conn) .sort(&sort) .search_term(q) + .my_user_id(user_id) .page(page) .limit(limit) .list() @@ -458,6 +459,7 @@ impl Perform for Search { CommunityQueryBuilder::create(conn) .sort(&sort) .search_term(q) + .my_user_id(user_id) .page(page) .limit(limit) .list() @@ -482,6 +484,7 @@ impl Perform for Search { PostQueryBuilder::create(conn) .sort(&sort) .show_nsfw(true) + .my_user_id(user_id) .community_id(community_id) .community_name(community_name) .url_search(q)