Pass user instead of their ap_id to User.block
authorFrancis Dinh <normandy@firemail.cc>
Sun, 20 May 2018 02:02:13 +0000 (22:02 -0400)
committerFrancis Dinh <normandy@firemail.cc>
Sun, 20 May 2018 02:02:13 +0000 (22:02 -0400)
lib/pleroma/web/activity_pub/transmogrifier.ex

index 887ffe2d0a26a8f7844256a2e1981c028f5ff580..47b84a469c121227779f7b2f6dcbb82976b1c454 100644 (file)
@@ -266,7 +266,7 @@ defmodule Pleroma.Web.ActivityPub.Transmogrifier do
          %User{} = blocker = User.get_or_fetch_by_ap_id(blocker),
          {:ok, activity} <- ActivityPub.block(blocker, blocked, false) do
       User.unfollow(blocker, blocked)
-      User.block(blocker, blocked.ap_id)
+      User.block(blocker, blocked)
       {:ok, activity}
     else
       e -> :error