1class DeliverPetitionEmailJob < ApplicationJob |
|
2 include EmailDelivery |
|
4 attr_reader :email |
|
|
6 def perform(**args) |
7 @email = args[:email] |
|
8 super |
|
9 end |
|
|
11 def create_email |
12 if signature.creator? |
|
13 mailer.email_creator petition, signature, email
|
|
14 else |
|
15 mailer.email_signer petition, signature, email
|
|
16 end |
|
17 end |
|
18end |