From: marcin mikołajczak Date: Tue, 28 Dec 2021 17:24:48 +0000 (+0100) Subject: AccountController.lookup: skip visibility check X-Git-Url: https://git.squeep.com/?a=commitdiff_plain;h=0dd1caa841386b99bcbe4adeef2c1cde5e6a377a;p=akkoma AccountController.lookup: skip visibility check Signed-off-by: marcin mikołajczak --- diff --git a/lib/pleroma/web/mastodon_api/controllers/account_controller.ex b/lib/pleroma/web/mastodon_api/controllers/account_controller.ex index 399a34217..6d8fcd026 100644 --- a/lib/pleroma/web/mastodon_api/controllers/account_controller.ex +++ b/lib/pleroma/web/mastodon_api/controllers/account_controller.ex @@ -493,11 +493,11 @@ defmodule Pleroma.Web.MastodonAPI.AccountController do end @doc "GET /api/v1/accounts/lookup" - def lookup(%{assigns: %{user: for_user}} = conn, %{acct: nickname} = _params) do + def lookup(conn, %{acct: nickname} = _params) do with %User{} = user <- User.get_by_nickname(nickname) do render(conn, "show.json", user: user, - for: for_user + skip_visibility_check: true ) else error -> user_visibility_error(conn, error)