blob: ede8cfccbfbf5fc7ddf9ea2d4b3270a65851282f (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
|
* Add the ability to intercept emails before previewing in a similar fashion
to how emails can be intercepted before delivery, e.g:
class CSSInlineStyler
def self.previewing_email(message)
# inline CSS styles
end
end
ActionMailer::Base.register_preview_interceptor CSSInlineStyler
Fixes #13622.
*Andrew White*
* Add mailer previews feature based on 37 Signals mail_view gem
*Andrew White*
* Calling `mail()` without arguments serves as getter for the current mail
message and keeps previously set headers.
Fixes #13090.
Example:
class MailerWithCallback < ActionMailer::Base
after_action :a_callback
def welcome
mail subject: "subject", to: ["joe@example.com"]
end
def a_callback
mail # => returns the current mail message
end
end
*Yves Senn*
* Instrument the generation of Action Mailer messages. The time it takes to
generate a message is written to the log.
*Daniel Schierbeck*
* Invoke mailer defaults as procs only if they are procs, do not convert with
`to_proc`. That an object is convertible to a proc does not mean it's meant
to be always used as a proc.
Fixes #11533.
*Alex Tsukernik*
Please check [4-0-stable](https://github.com/rails/rails/blob/4-0-stable/actionmailer/CHANGELOG.md) for previous changes.
|