Merge branch 'develop' into issue/733
authorMaksim Pechnikov <parallel588@gmail.com>
Mon, 16 Sep 2019 04:34:22 +0000 (07:34 +0300)
committerMaksim Pechnikov <parallel588@gmail.com>
Mon, 16 Sep 2019 04:34:22 +0000 (07:34 +0300)
1  2 
lib/pleroma/web/activity_pub/transmogrifier.ex

index acd61bda3c19905a56c7b999f9620ae1343595e3,acb3087d06defa4d869699ee08642fe05fb9e3fb..2fbb1662381b2cc1503a3195dcb8edf39795f0cb
@@@ -1049,9 -1050,9 +1050,9 @@@ defmodule Pleroma.Web.ActivityPub.Trans
      with %User{local: false} = user <- User.get_cached_by_ap_id(ap_id),
           {:ok, data} <- ActivityPub.fetch_and_prepare_user_from_ap_id(ap_id),
           already_ap <- User.ap_enabled?(user),
 -         {:ok, user} <- user |> User.upgrade_changeset(data) |> User.update_and_set_cache() do
 -      unless already_ap do
 +         {:ok, user} <- upgrade_user(user, data) do
 +      if not already_ap do
-         PleromaJobQueue.enqueue(:transmogrifier, __MODULE__, [:user_upgrade, user])
+         TransmogrifierWorker.enqueue("user_upgrade", %{"user_id" => user.id})
        end
  
        {:ok, user}