fix purge_removed_accounts task should suspend account before delete it (#6521)
This commit is contained in:
parent
a7171af0a3
commit
f69d7cb43b
1 changed files with 2 additions and 0 deletions
|
@ -752,6 +752,7 @@ namespace :mastodon do
|
||||||
|
|
||||||
if [404, 410].include?(res.code)
|
if [404, 410].include?(res.code)
|
||||||
if options[:force]
|
if options[:force]
|
||||||
|
SuspendAccountService.new.call(account)
|
||||||
account.destroy
|
account.destroy
|
||||||
else
|
else
|
||||||
progress_bar.pause
|
progress_bar.pause
|
||||||
|
@ -764,6 +765,7 @@ namespace :mastodon do
|
||||||
if confirm.casecmp('n').zero?
|
if confirm.casecmp('n').zero?
|
||||||
next
|
next
|
||||||
else
|
else
|
||||||
|
SuspendAccountService.new.call(account)
|
||||||
account.destroy
|
account.destroy
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue