Commit 6453f7ca authored by jplang's avatar jplang

Remove iteration in ApplicationHelper#syntax_highlight_lines (#24713).

Patch by Go MAEDA.

git-svn-id: https://svn.redmine.org/redmine/trunk@16164 e93f8b46-1217-0410-a6f0-8f06a7374b81
parent de72e2ad
......@@ -466,9 +466,7 @@ module ApplicationHelper
end
def syntax_highlight_lines(name, content)
lines = []
syntax_highlight(name, content).each_line { |line| lines << line }
lines
syntax_highlight(name, content).each_line.to_a
end
def syntax_highlight(name, content)
......
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