+ plug(
+ OAuthScopesPlug,
+ %{scopes: ["read:statuses"]}
+ when action in [:conversation, :conversation_statuses]
+ )
+
+ plug(
+ OAuthScopesPlug,
+ %{scopes: ["write:statuses"]}
+ when action in [:react_with_emoji, :unreact_with_emoji]
+ )
+
+ plug(
+ OAuthScopesPlug,
+ %{scopes: ["write:conversations"]} when action == :update_conversation
+ )
+
+ plug(OAuthScopesPlug, %{scopes: ["write:notifications"]} when action == :read_notification)
+
+ plug(Pleroma.Plugs.EnsurePublicOrAuthenticatedPlug)
+
+ def emoji_reactions_by(%{assigns: %{user: user}} = conn, %{"id" => activity_id} = params) do