hackathon_manager 0.6.4 → 0.6.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/app/mailers/mailer.rb +10 -4
- data/lib/hackathon_manager/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a51352083b4efe91bc92f29569313d4cae2411f1
|
4
|
+
data.tar.gz: 67421b84d0631aa2df21a2bf15dc83f7ba60c43c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7c63629d0dd82b8c317f929e320b73884fe947a3ca517a36f9d68b4e817b490225ad8cbe170056633b75b867bf03da186478c15b834ee6ee58c571d90fe9b925
|
7
|
+
data.tar.gz: 4725f0733645437c9eaf9496f95de77ecbcd87cec56f880620fae19d49a187e9fd99d6d5f297dbd30242849e5694b6b94f7c53a64c718d98e247b61dce17e13e
|
data/app/mailers/mailer.rb
CHANGED
@@ -7,13 +7,13 @@ class Mailer < ApplicationMailer
|
|
7
7
|
def application_confirmation_email(questionnaire_id)
|
8
8
|
@questionnaire = Questionnaire.find_by_id(questionnaire_id)
|
9
9
|
return unless @questionnaire.present? && @questionnaire.user.present?
|
10
|
-
mail_questionnaire("Application Received")
|
10
|
+
mail_questionnaire("Application Received", transactional: true)
|
11
11
|
end
|
12
12
|
|
13
13
|
def rsvp_confirmation_email(questionnaire_id)
|
14
14
|
@questionnaire = Questionnaire.find_by_id(questionnaire_id)
|
15
15
|
return unless @questionnaire.present? && @questionnaire.user.present?
|
16
|
-
mail_questionnaire("RSVP Confirmation")
|
16
|
+
mail_questionnaire("RSVP Confirmation", transactional: true)
|
17
17
|
end
|
18
18
|
|
19
19
|
def accepted_email(questionnaire_id)
|
@@ -75,10 +75,16 @@ class Mailer < ApplicationMailer
|
|
75
75
|
"\"#{name}\" <#{email}>"
|
76
76
|
end
|
77
77
|
|
78
|
-
def mail_questionnaire(subject)
|
78
|
+
def mail_questionnaire(subject, sparkpost_data = {})
|
79
79
|
mail(
|
80
80
|
to: pretty_email(@questionnaire.full_name, @questionnaire.user.email),
|
81
|
-
subject: subject
|
81
|
+
subject: subject,
|
82
|
+
sparkpost_data: sparkpost_data
|
82
83
|
)
|
84
|
+
rescue SparkPostRails::DeliveryException => e
|
85
|
+
error_code_to_not_retry = [
|
86
|
+
"1902" # Generation rejection
|
87
|
+
]
|
88
|
+
raise e unless e.blank? || error_code_to_not_retry.include?(e.service_code)
|
83
89
|
end
|
84
90
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: hackathon_manager
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.6.
|
4
|
+
version: 0.6.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Stuart Olivera
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-01
|
11
|
+
date: 2018-02-01 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|