about summary refs log tree commit diff
path: root/app/workers/scheduler/user_cleanup_scheduler.rb
diff options
context:
space:
mode:
Diffstat (limited to 'app/workers/scheduler/user_cleanup_scheduler.rb')
-rw-r--r--app/workers/scheduler/user_cleanup_scheduler.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/workers/scheduler/user_cleanup_scheduler.rb b/app/workers/scheduler/user_cleanup_scheduler.rb
index dde195bff..626fb1652 100644
--- a/app/workers/scheduler/user_cleanup_scheduler.rb
+++ b/app/workers/scheduler/user_cleanup_scheduler.rb
@@ -6,7 +6,7 @@ class Scheduler::UserCleanupScheduler
   sidekiq_options unique: :until_executed
 
   def perform
-    User.where('confirmed_at is NULL AND confirmation_sent_at <= ?', 2.days.ago).find_in_batches do |batch|
+    User.where('confirmed_at is NULL AND confirmation_sent_at <= ?', 2.days.ago).reorder(nil).find_in_batches do |batch|
       Account.where(id: batch.map(&:account_id)).delete_all
       User.where(id: batch.map(&:id)).delete_all
     end