Limit activity types accepted to outbox to only 'Create'

This commit is contained in:
sxsdv1 2018-12-29 18:22:40 +01:00
parent 569bad8210
commit 1e781715c8

View File

@ -165,7 +165,10 @@ defmodule Pleroma.Web.ActivityPub.ActivityPubController do
end end
end end
def update_outbox(%{assigns: %{user: user}} = conn, %{"nickname" => nickname} = params) do def update_outbox(
%{assigns: %{user: user}} = conn,
%{"nickname" => nickname, "type" => "Create"} = params
) do
if nickname == user.nickname do if nickname == user.nickname do
actor = user.ap_id() actor = user.ap_id()