postmark_customized 0.1.1 → 0.1.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +3 -0
- data/lib/griddler/postmark_customized/adapter.rb +3 -1
- data/lib/griddler/postmark_customized/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d71f5cf4dabf5c75112aa2c7e90259eb38ea2a1671db856504c609afd4d5bd86
|
4
|
+
data.tar.gz: e0ef7fb656c066ad2b796eca9163906da482219e25a879ad56e30ef9b22581c9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7f6840c519c42f0206c08f81e2592a9f5cd8325b3ddc407e6e289c4f9bdc6a83857676ba120833c92e4334b44e0efd7a0d8a4a6803b0fa5bc323cba174ddee83
|
7
|
+
data.tar.gz: 582270f23828f48c9eece5efebe76babf92ba54c2f37c442e6cb4e99381ed9697843e7500ece787cd517eb883bbb9abdef8c2d264966cdcaee684cd014512e12
|
data/README.md
CHANGED
@@ -26,6 +26,9 @@ Or install it yourself as:
|
|
26
26
|
Create an initializer with the following settings:
|
27
27
|
|
28
28
|
```ruby
|
29
|
+
# Require adapter here or Griddler will be unable to find adapter for some reason
|
30
|
+
require 'griddler/postmark_customized'
|
31
|
+
|
29
32
|
Griddler.configure do |config|
|
30
33
|
config.email_service = :postmark_customized
|
31
34
|
end
|
@@ -68,7 +68,9 @@ module Griddler
|
|
68
68
|
end
|
69
69
|
|
70
70
|
def create_tempfile(attachment)
|
71
|
-
filename = attachment[:Name].
|
71
|
+
filename = attachment[:Name].split('.')
|
72
|
+
filename[0] = filename[0].gsub(/\/|\\/, '_')[0..130]
|
73
|
+
filename[1] = ".#{filename[1]}" if filename[1]
|
72
74
|
tempfile = Tempfile.new(filename, Dir::tmpdir, encoding: 'ascii-8bit')
|
73
75
|
tempfile.write(content(attachment))
|
74
76
|
tempfile.rewind
|