fix format

This commit is contained in:
Egor Kislitsyn 2019-04-11 17:28:12 +07:00
parent db4badc6aa
commit 46bd5c1d87

View File

@ -1150,7 +1150,6 @@ defmodule Pleroma.User do
) )
end end
def deactivate_async(user, status \\ true) do def deactivate_async(user, status \\ true) do
PleromaJobQueue.enqueue(:user, __MODULE__, [:deactivate_async, user, status]) PleromaJobQueue.enqueue(:user, __MODULE__, [:deactivate_async, user, status])
end end
@ -1160,7 +1159,8 @@ defmodule Pleroma.User do
def deactivate(%User{} = user, status \\ true) do def deactivate(%User{} = user, status \\ true) do
info_cng = User.Info.set_activation_status(user.info, status) info_cng = User.Info.set_activation_status(user.info, status)
with {:ok, user} <- user with {:ok, user} <-
user
|> change() |> change()
|> put_embed(:info, info_cng) |> put_embed(:info, info_cng)
|> update_and_set_cache(), |> update_and_set_cache(),