mirror of
https://github.com/jekyll/jekyll.git
synced 2026-02-02 10:45:24 -05:00
Incorporate code review feedback
This commit is contained in:
@@ -95,13 +95,10 @@ module Jekyll
|
||||
end
|
||||
|
||||
def collect_urls_case_insensitive(urls, things, destination)
|
||||
things.each do |thing|
|
||||
dest = thing.destination(destination)
|
||||
if urls[dest.downcase]
|
||||
urls[dest.downcase] << dest
|
||||
else
|
||||
urls[dest.downcase] = [dest]
|
||||
end
|
||||
things.inject(urls) do |memo, thing|
|
||||
dest = thing.destination(destination)
|
||||
(memo[dest.downcase] ||= []) << dest
|
||||
memo
|
||||
end
|
||||
urls
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user