projects
/
akkoma
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c6d4133
)
Also purge the user in User.perform/2
author
Alex Gleason
<alex@alexgleason.me>
Wed, 30 Jun 2021 03:53:33 +0000
(22:53 -0500)
committer
Alex Gleason
<alex@alexgleason.me>
Wed, 30 Jun 2021 03:53:33 +0000
(22:53 -0500)
lib/pleroma/user.ex
patch
|
blob
|
history
diff --git
a/lib/pleroma/user.ex
b/lib/pleroma/user.ex
index 406a7f5f99b9b4ef772a0782a8318d2247f6171b..f3cf3c69b5e980c34aa277718292757abd10edc5 100644
(file)
--- a/
lib/pleroma/user.ex
+++ b/
lib/pleroma/user.ex
@@
-1724,6
+1724,7
@@
defmodule Pleroma.User do
end
def delete(%User{} = user) do
+ # Purge the user immediately
purge(user)
BackgroundWorker.enqueue("delete_user", %{"user_id" => user.id})
end
@@
-1749,6
+1750,9
@@
defmodule Pleroma.User do
@spec perform(atom(), User.t()) :: {:ok, User.t()}
def perform(:delete, %User{} = user) do
+ # Purge the user again, in case perform/2 is called directly
+ purge(user)
+
# Remove all relationships
user
|> get_followers()