From 4c289e924e2ef7863a2c95b74f71fd83969b7827 Mon Sep 17 00:00:00 2001 From: rinpatch Date: Wed, 17 Apr 2019 16:35:01 +0300 Subject: [PATCH] Fix delete-by_ap_id to expect not only embeded objects --- lib/pleroma/activity.ex | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/pleroma/activity.ex b/lib/pleroma/activity.ex index 478d16356..9043530c9 100644 --- a/lib/pleroma/activity.ex +++ b/lib/pleroma/activity.ex @@ -230,6 +230,7 @@ defmodule Pleroma.Activity do |> Repo.delete_all() |> elem(1) |> Enum.find(fn + %{data: %{"type" => "Create", "object" => ap_id}} when is_binary(ap_id) -> ap_id == id %{data: %{"type" => "Create", "object" => %{"id" => ap_id}}} -> ap_id == id _ -> nil end) -- 2.45.2