diff --git a/lib/mastodon/cli/statuses.rb b/lib/mastodon/cli/statuses.rb index 0d6018a2b9..7acf3f9b77 100644 --- a/lib/mastodon/cli/statuses.rb +++ b/lib/mastodon/cli/statuses.rb @@ -120,7 +120,7 @@ module Mastodon::CLI say('Beginning removal of now-orphaned media attachments to free up disk space...') - scope = MediaAttachment.reorder(nil).unattached.where('created_at < ?', options[:days].pred.days.ago) + scope = MediaAttachment.unattached.where('created_at < ?', options[:days].pred.days.ago) processed = 0 removed = 0 progress = create_progress_bar(scope.count)