Transmogrifier: Remove duplicate code.
authorlain <lain@soykaf.club>
Mon, 10 Aug 2020 13:31:36 +0000 (15:31 +0200)
committerlain <lain@soykaf.club>
Mon, 10 Aug 2020 13:31:36 +0000 (15:31 +0200)
lib/pleroma/web/activity_pub/transmogrifier.ex

index 7381d4476b06dd1526be8642889e228fd33fafec..2f04cc6ffb496fe4097508413892bbe58419ebd3 100644 (file)
@@ -644,16 +644,6 @@ defmodule Pleroma.Web.ActivityPub.Transmogrifier do
     end
   end
 
-  def handle_incoming(
-        %{"type" => "Create", "object" => %{"type" => "ChatMessage"}} = data,
-        _options
-      ) do
-    with {:ok, %User{}} <- ObjectValidator.fetch_actor(data),
-         {:ok, activity, _} <- Pipeline.common_pipeline(data, local: false) do
-      {:ok, activity}
-    end
-  end
-
   def handle_incoming(%{"type" => type} = data, _options)
       when type in ~w{Like EmojiReact Announce} do
     with :ok <- ObjectValidator.fetch_actor_and_object(data),