fix(maintenance task): pass a collection instead of an array
This commit is contained in:
parent
7ab8345b39
commit
0a8075d8a4
2 changed files with 2 additions and 2 deletions
|
@ -3,7 +3,7 @@
|
|||
module Maintenance
|
||||
class BackfillBulkMessagesWithProcedureIdTask < MaintenanceTasks::Task
|
||||
def collection
|
||||
BulkMessage.all.filter { |bm| bm.procedure.nil? && bm.groupe_instructeurs.present? }
|
||||
BulkMessage.where(procedure: nil).where.missing(:groupe_instructeurs)
|
||||
end
|
||||
|
||||
def process(element)
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
module Maintenance
|
||||
class DestroyIncompleteBulkMessagesTask < MaintenanceTasks::Task
|
||||
def collection
|
||||
BulkMessage.all.filter { |bm| bm.procedure.nil? && bm.groupe_instructeurs.blank? }
|
||||
BulkMessage.where(procedure: nil).where.missing(:groupe_instructeurs)
|
||||
end
|
||||
|
||||
def process(element)
|
||||
|
|
Loading…
Reference in a new issue