Commit 8a47f70e authored by georg's avatar georg

Add visual separator to the end of the 'pseudoheaders' block

This should help users of Apple Mail, which jams this block and the body
together. Hopefully, this change makes it easier to dinstiguish both
parts from each other.

Closes #348
parent 77687f29
Pipeline #32722 passed with stages
in 17 minutes and 32 seconds
......@@ -8,6 +8,7 @@ This project adheres to [Semantic Versioning](http://semver.org/).
### Added
* New option for lists to include their public keys in the headers of outgoing emails (conforming with Autocrypt, https://autocrypt.org/). Defaults to true. (#335)
* Add visual separator (78 dashes) to the end of the 'pseudoheaders' block: This should help users of Apple Mail, which jams this block and the body together. Hopefully, this change makes it easier to dinstiguish both parts from each other. (#348)
### Fixed
......
......@@ -333,7 +333,8 @@ module Mail
end
def pseudoheaders(list)
(standard_pseudoheaders(list) + dynamic_pseudoheaders).flatten.join("\n") + "\n"
separator = '------------------------------------------------------------------------------'
(standard_pseudoheaders(list) + dynamic_pseudoheaders).flatten.join("\n") + "\n" + separator + "\n"
end
def add_msgids(list, orig)
......
......@@ -39,7 +39,8 @@ describe Schleuder::Runner do
Schleuder::Runner.new().run(mail, list.email)
message = Mail::TestMailer.deliveries.first
content_part = message.parts.first
pseudoheaders = "From: Nina Siessegger <schleuder@example.org>\nSig: Unsigned"
separator = '------------------------------------------------------------------------------'
pseudoheaders = "From: Nina Siessegger <schleuder@example.org>\nSig: Unsigned\n#{separator}\n"
expect(content_part.parts.first.body).to include(pseudoheaders)
expect(content_part.parts.first.body).not_to include('To:')
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment