commit: 42ea480e95862c09c07f6b4711648c192a66fdf5
parent: c814f22030c1341ec337bdd1c446536597e683e2
Author: lain <lain@soykaf.club>
Date: Mon, 20 Jan 2020 13:49:06 +0000
Merge branch 'fix-emoji-reactions-oauth-scope' into 'develop'
Pleroma API: `emoji_reactions_by` does not need authorization
See merge request pleroma/pleroma!2117
Diffstat:
2 files changed, 1 insertion(+), 6 deletions(-)
diff --git a/lib/pleroma/web/pleroma_api/controllers/pleroma_api_controller.ex b/lib/pleroma/web/pleroma_api/controllers/pleroma_api_controller.ex
@@ -23,7 +23,7 @@ defmodule Pleroma.Web.PleromaAPI.PleromaAPIController do
plug(
OAuthScopesPlug,
%{scopes: ["read:statuses"]}
- when action in [:conversation, :conversation_statuses, :emoji_reactions_by]
+ when action in [:conversation, :conversation_statuses]
)
plug(
diff --git a/test/web/pleroma_api/controllers/pleroma_api_controller_test.exs b/test/web/pleroma_api/controllers/pleroma_api_controller_test.exs
@@ -57,11 +57,6 @@ defmodule Pleroma.Web.PleromaAPI.PleromaAPIControllerTest do
{:ok, activity} = CommonAPI.post(user, %{"status" => "#cofe"})
- conn =
- conn
- |> assign(:user, user)
- |> assign(:token, insert(:oauth_token, user: user, scopes: ["read:statuses"]))
-
result =
conn
|> get("/api/v1/pleroma/statuses/#{activity.id}/emoji_reactions_by")