griddler 0.4.0 → 0.4.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +2 -2
- data/lib/griddler/adapters/postmark_adapter.rb +10 -1
- data/lib/griddler/configuration.rb +1 -0
- data/lib/griddler/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: 25118b339d00976897148f6999e07b31a7b430e5
|
4
|
+
data.tar.gz: 10c89b94dd65253620018490b1b84290885ee9b1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d33d3fac3fdad15c1ee4b1aa957fa667f52d5aad4c17f5aa7572b0199c33598a283689837192f9373faff4dd32b1ac951e8fceda4db7de27ed530d5da946806c
|
7
|
+
data.tar.gz: dd09ef830ab90a1e6cebbef4cefc744cb0ae94a1a21cf644ad6a93b3052a667b05683045202a607a8117caa7cb94a3b2efd6b43a7e06b8b194d6c082237b1188
|
data/README.md
CHANGED
@@ -110,8 +110,8 @@ end
|
|
110
110
|
* `config.to` is the format of the returned value for the `:to` key in
|
111
111
|
the email object. `:hash` will return all options within a -- (surprise!) -- hash.
|
112
112
|
* `config.email_service` tells Griddler which email service you are using. The supported
|
113
|
-
email service options are
|
114
|
-
multipart format) and
|
113
|
+
email service options are `:sendgrid` (the default), `:cloudmailin` (expects
|
114
|
+
multipart format) and `:postmark`.
|
115
115
|
|
116
116
|
Testing In Your App
|
117
117
|
-------------------
|
@@ -12,7 +12,7 @@ module Griddler
|
|
12
12
|
|
13
13
|
def normalize_params
|
14
14
|
{
|
15
|
-
to: params[:ToFull]
|
15
|
+
to: full_email(params[:ToFull].first),
|
16
16
|
from: params[:FromFull][:Email],
|
17
17
|
subject: params[:Subject],
|
18
18
|
text: params[:TextBody],
|
@@ -25,6 +25,15 @@ module Griddler
|
|
25
25
|
|
26
26
|
attr_reader :params
|
27
27
|
|
28
|
+
def full_email(contact_info)
|
29
|
+
email = contact_info[:Email]
|
30
|
+
if contact_info[:Name].present?
|
31
|
+
"#{contact_info[:Name]} <#{email}>"
|
32
|
+
else
|
33
|
+
email
|
34
|
+
end
|
35
|
+
end
|
36
|
+
|
28
37
|
def attachment_files
|
29
38
|
attachments = Array(params[:Attachments])
|
30
39
|
|
data/lib/griddler/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: griddler
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Caleb Thompson
|
@@ -11,7 +11,7 @@ authors:
|
|
11
11
|
autorequire:
|
12
12
|
bindir: bin
|
13
13
|
cert_chain: []
|
14
|
-
date: 2013-03-
|
14
|
+
date: 2013-03-26 00:00:00.000000000 Z
|
15
15
|
dependencies:
|
16
16
|
- !ruby/object:Gem::Dependency
|
17
17
|
name: rails
|