Fix `Transmogrifier.upgrade_user_from_ap_id/1`

This commit is contained in:
Egor Kislitsyn 2019-09-16 19:26:00 +07:00
parent 409e701ab8
commit 085d014f08
1 changed files with 1 additions and 1 deletions

View File

@ -1050,7 +1050,7 @@ def upgrade_user_from_ap_id(ap_id) do
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
{:ok, user} <- user |> User.upgrade_changeset(data, true) |> User.update_and_set_cache() do
unless already_ap do
TransmogrifierWorker.enqueue("user_upgrade", %{"user_id" => user.id})
end