Merge branch 'delete-account-fix' into 'develop'
[akkoma] / lib / pleroma / workers / transmogrifier_worker.ex
1 # Pleroma: A lightweight social networking server
2 # Copyright © 2017-2021 Pleroma Authors <https://pleroma.social/>
3 # SPDX-License-Identifier: AGPL-3.0-only
4
5 defmodule Pleroma.Workers.TransmogrifierWorker do
6 alias Pleroma.User
7
8 use Pleroma.Workers.WorkerHelper, queue: "transmogrifier"
9
10 @impl Oban.Worker
11 def perform(%Job{args: %{"op" => "user_upgrade", "user_id" => user_id}}) do
12 user = User.get_cached_by_id(user_id)
13 Pleroma.Web.ActivityPub.Transmogrifier.perform(:user_upgrade, user)
14 end
15 end