提交 ab83800c 编写于 作者: P Prem Sichanugrist 提交者: Pratik Naik

Hide '/rails/info/properties' from 'rake routes' [#3793 state:resolved]

Signed-off-by: NPratik Naik <pratiknaik@gmail.com>
上级 df8852d0
......@@ -7,6 +7,7 @@ task :routes => :environment do
reqs = route.requirements.empty? ? "" : route.requirements.inspect
{:name => name, :verb => route.verb.to_s, :path => route.path, :reqs => reqs}
end
routes.reject!{ |r| r[:path] == "/rails/info/properties" } # skip the route if it's internal info route
name_width = routes.collect {|r| r[:name]}.collect {|n| n.length}.max
verb_width = routes.collect {|r| r[:verb]}.collect {|v| v.length}.max
path_width = routes.collect {|r| r[:path]}.collect {|s| s.length}.max
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册