Sha256: 1f7dbb6484dc8a1afb721398a6ab60830ea63291532c6c19ac98363c3aa85e25
Contents?: true
Size: 402 Bytes
Versions: 62
Compression:
Stored size: 402 Bytes
Contents
module Workarea class OrderReminder include Sidekiq::Worker def perform(*) # This while loop is necessary because # we're changing the count as we go while Order.need_reminding.any? Order.need_reminding.each_by(50) do |order| order.mark_as_reminded! Storefront::OrderMailer.reminder(order.id).deliver_now end end end end end
Version data entries
62 entries across 62 versions & 1 rubygems