1class NotifyCreatorsThatModerationIsDelayedJob < ApplicationJob |
|
2 queue_as :high_priority |
|
|
4 def perform(subject, body) |
5 petitions.find_each do |petition| |
|
6 NotifyCreatorThatModerationIsDelayedJob.perform_later(petition.creator, subject, body) |
|
7 end |
|
8 end |
|
10 private
|
|
|
12 def petitions |
13 Petition.overdue_in_moderation |
|
14 end |
|
15end |