Skip to content
Browse files

Extract variable out of loop

  • Loading branch information...
1 parent 42da93c commit 1ed6ff1006fb5fd816b8b0267754b3113828e918 @vipulnsward vipulnsward committed
Showing with 2 additions and 1 deletion.
  1. +2 −1 actionmailer/lib/action_mailer/mail_helper.rb
View
3 actionmailer/lib/action_mailer/mail_helper.rb
@@ -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

0 comments on commit 1ed6ff1

Please sign in to comment.
Something went wrong with that request. Please try again.