From: rinpatch Date: Wed, 17 Apr 2019 13:35:01 +0000 (+0300) Subject: Fix delete-by_ap_id to expect not only embeded objects X-Git-Url: https://git.squeep.com/?a=commitdiff_plain;h=4c289e924e2ef7863a2c95b74f71fd83969b7827;p=akkoma Fix delete-by_ap_id to expect not only embeded objects --- 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)