From cd4e9b6932e2ea1548ee4ee000c13ff53eb16919 Mon Sep 17 00:00:00 2001 From: Aevann1 Date: Wed, 29 Dec 2021 10:09:43 +0200 Subject: [PATCH] fds --- files/routes/search.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/files/routes/search.py b/files/routes/search.py index 84181c6ea..26639f56c 100644 --- a/files/routes/search.py +++ b/files/routes/search.py @@ -67,7 +67,7 @@ def searchposts(v): if 'author' in criteria: author = get_user(criteria['author']) - if author.is_private: + if author.is_private and v.admin_level < 2 and not v.eye: if request.headers.get("Authorization"): return {"error": f"@{author.username}'s profile is private; You can't use the 'author' syntax on them"} return render_template(f"{template}search.html", @@ -214,7 +214,7 @@ def searchcomments(v): if 'author' in criteria: author = get_user(criteria['author']) - if author.is_private: + if author.is_private and v.admin_level < 2 and not v.eye: if request.headers.get("Authorization"): return {"error": f"@{author.username}'s profile is private; You can't use the 'author' syntax on them"}