pboling / rack-insight

Debugging toolbar for Rack applications implemented as middleware
http://railsbling.com/retired_projects/rack-insight/
MIT License
151 stars 22 forks source link

Undefined method Rails 4... #23

Closed Altonymous closed 9 years ago

Altonymous commented 11 years ago

rails 4.0 ruby 2.0.0-p247 rack-insight 0.5.26

NoMethodError at / undefined method `any?' for #ActionDispatch::Request::Session:0x007fc6158c7390

lib/rack/insight/panels/request_variables_panel.rb:8

4     def after(env,status,headers,body)
5       sections = {}
6       sections["GET"] = sort(@request.GET) if @request.GET.any?
7       sections["POST"] = sort(@request.POST) if @request.POST.any?
8       sections["Session"] = sort(@request.env["rack.session"]) if @request.env["rack.session"] && @request.env["rack.session"].any?
9       sections["Cookies"] = sort(@request.env["rack.request.cookie_hash"]) if @request.env["rack.request.cookie_hash"] && @request.env["rack.request.cookie_hash"].any?
10      server, rack = split_and_filter_env(@env)
11      sections["SERVER VARIABLES"] = sort(server)
12      sections["Rack ENV"] = sort(rack)
pboling commented 11 years ago

Thanks, I'll push a fix soon! I've just gotten all the spec tests passing!

pboling commented 9 years ago

This is fixed in master.