Skip to content

Commit

Permalink
Merge pull request rails#10587 from vipulnsward/indent_var
Browse files Browse the repository at this point in the history
Extract variable out of loop
  • Loading branch information
rafaelfranca committed May 13, 2013
2 parents 4c0fa44 + 1ed6ff1 commit b44f086
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion actionmailer/lib/action_mailer/mail_helper.rb
Expand Up @@ -46,8 +46,9 @@ def format_paragraph(text, len = 72, indent = 2)
end
end

indentation = " " * indent
sentences.map { |sentence|
"#{" " * indent}#{sentence.join(' ')}"
"#{indentation}#{sentence.join(' ')}"
}.join "\n"
end
end
Expand Down

0 comments on commit b44f086

Please sign in to comment.