diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2019-08-22 21:55:56 +0200 |
---|---|---|
committer | multiple creatures <dev@multiple-creature.party> | 2020-02-27 13:43:13 -0600 |
commit | 422b59808b4818171e057e1a459de153816bf505 (patch) | |
tree | 5320830d5d3146c9032a0e975a069a4a1be76253 /app/models/form/status_batch.rb | |
parent | 165f53238655bf87f27981282ca8deb71474c86f (diff) |
port tootsuite#11623 to monsterfork: Add soft delete for statuses for instant deletes through API
* Add soft delete for statuses to allow them to appear instant * Allow reporting soft-deleted statuses and show them in the admin UI * Change index for getting an account's statuses
Diffstat (limited to 'app/models/form/status_batch.rb')
-rw-r--r-- | app/models/form/status_batch.rb | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/app/models/form/status_batch.rb b/app/models/form/status_batch.rb index 3b82b5551..91710a5d7 100644 --- a/app/models/form/status_batch.rb +++ b/app/models/form/status_batch.rb @@ -33,6 +33,7 @@ class Form::StatusBatch def delete_statuses Status.where(id: status_ids).reorder(nil).find_each do |status| + status.discard RemovalWorker.perform_async(status.id, redraft: false) Tombstone.find_or_create_by(uri: status.uri, account: status.account, by_moderator: true) log_action :destroy, status |