Extract variable out of loop

This commit is contained in:
Vipul A M 2013-05-13 09:20:19 +05:30
parent 42da93ca30
commit 1ed6ff1006

@ -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