From: Maksim Pechnikov Date: Mon, 16 Sep 2019 04:34:22 +0000 (+0300) Subject: Merge branch 'develop' into issue/733 X-Git-Url: https://git.squeep.com/?a=commitdiff_plain;h=d75bc728e7e309174373e234079aa4825c81ab3e;p=akkoma Merge branch 'develop' into issue/733 --- d75bc728e7e309174373e234079aa4825c81ab3e diff --cc lib/pleroma/web/activity_pub/transmogrifier.ex index acd61bda3,acb3087d0..2fbb16623 --- a/lib/pleroma/web/activity_pub/transmogrifier.ex +++ b/lib/pleroma/web/activity_pub/transmogrifier.ex @@@ -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}