Vote #73337
未完了mail_handler.rb - email message body has trailing space - alters wiki view
0%
説明
Redmine 2.2.2, Ruby 1.8.7, Rails 3.2.11 on EL6
app/models/mail_handler.rb, line 475:
body.strip
This leaves a trailing space on all lines of the body of the email:
Testing, Testing 2 new lines... Still testing -- *Me* Office: (555) 555-1212 Email: me@example.net
Which looks like:
Testing, Testing
2 new lines... Still testing
--
Me
Office: (555) 555-1212
Email: me@example.net
Possible fix - remove trailing space by:
#body.strip
newbody = ""
body.each {|l| newbody << l.gsub(/^[ ]/, '')}
body = newbody
journals
Possible fix - remove LEADING space by:
<pre><code class="ruby">
#body.strip
newbody = ""
body.each {|l| newbody << l.gsub(/^[ ]/, '')}
body = newbody
</code></pre>
--------------------------------------------------------------------------------