diff options
author | U-ESCAPEE\Mack <mack@agilereasoning.com> | 2008-09-04 12:03:29 -0400 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2008-09-09 23:29:29 -0500 |
commit | f3f7d166d8e7a1a2e15371f2870115406e1aaac2 (patch) | |
tree | 078c89ece33a4ec32c73d0170a6da351cfe381b0 /actionmailer | |
parent | 704fc3785eb4c0bca6a37060b551f09489352b6e (diff) | |
download | rails-f3f7d166d8e7a1a2e15371f2870115406e1aaac2.tar.gz rails-f3f7d166d8e7a1a2e15371f2870115406e1aaac2.tar.bz2 rails-f3f7d166d8e7a1a2e15371f2870115406e1aaac2.zip |
Fixed problem causes by leftover backup templates ending in tilde [state:committed #969]
Signed-off-by: David Heinemeier Hansson <david@loudthinking.com>
Diffstat (limited to 'actionmailer')
-rw-r--r-- | actionmailer/lib/action_mailer/base.rb | 2 | ||||
-rw-r--r-- | actionmailer/test/fixtures/test_mailer/implicitly_multipart_example.text.html.erb~ | 10 |
2 files changed, 11 insertions, 1 deletions
diff --git a/actionmailer/lib/action_mailer/base.rb b/actionmailer/lib/action_mailer/base.rb index 96e514e0db..bfe435550b 100644 --- a/actionmailer/lib/action_mailer/base.rb +++ b/actionmailer/lib/action_mailer/base.rb @@ -466,7 +466,7 @@ module ActionMailer #:nodoc: template = template_root["#{mailer_name}/#{File.basename(path)}"] # Skip unless template has a multipart format - next unless template.multipart? + next unless template && template.multipart? @parts << Part.new( :content_type => template.content_type, diff --git a/actionmailer/test/fixtures/test_mailer/implicitly_multipart_example.text.html.erb~ b/actionmailer/test/fixtures/test_mailer/implicitly_multipart_example.text.html.erb~ new file mode 100644 index 0000000000..946d99ede5 --- /dev/null +++ b/actionmailer/test/fixtures/test_mailer/implicitly_multipart_example.text.html.erb~ @@ -0,0 +1,10 @@ +<html> + <body> + HTML formatted message to <strong><%= @recipient %></strong>. + </body> +</html> +<html> + <body> + HTML formatted message to <strong><%= @recipient %></strong>. + </body> +</html> |