Defect #4292
closedNoMethodError (undefined method `length' for nil:NilClass) after upgrading
0%
Description
As described by Stefan Kesberg at http://www.redmine.org/boards/2/topics/9757, after upgrading to the latest revision in the trunk (r3092 in my case) you get an error when trying to open redmine in the browser if you had a valid session of a previous redmine version (0.8.7 in my case).
As Phil Hord explains in the same thread, the error goes away if you clear your redmine cookies in your browser. Anyway, this situation should not occur.
The stacktrace follows:
Processing WelcomeController#index (for x.x.x.x at 2009-11-25 18:27:09) [GET]
Parameters: {"action"=>"index", "controller"=>"welcome"}
NoMethodError (undefined method `length' for nil:NilClass):
app/controllers/application_controller.rb:48:in `find_current_user'
app/controllers/application_controller.rb:42:in `user_setup'
/opt/ruby-enterprise-1.8.7-2009.10/lib/ruby/1.8/webrick/httpserver.rb:104:in `service'
/opt/ruby-enterprise-1.8.7-2009.10/lib/ruby/1.8/webrick/httpserver.rb:65:in `run'
/opt/ruby-enterprise-1.8.7-2009.10/lib/ruby/1.8/webrick/server.rb:173:in `start_thread'
/opt/ruby-enterprise-1.8.7-2009.10/lib/ruby/1.8/webrick/server.rb:162:in `start'
/opt/ruby-enterprise-1.8.7-2009.10/lib/ruby/1.8/webrick/server.rb:162:in `start_thread'
/opt/ruby-enterprise-1.8.7-2009.10/lib/ruby/1.8/webrick/server.rb:95:in `start'
/opt/ruby-enterprise-1.8.7-2009.10/lib/ruby/1.8/webrick/server.rb:92:in `each'
/opt/ruby-enterprise-1.8.7-2009.10/lib/ruby/1.8/webrick/server.rb:92:in `start'
/opt/ruby-enterprise-1.8.7-2009.10/lib/ruby/1.8/webrick/server.rb:23:in `start'
/opt/ruby-enterprise-1.8.7-2009.10/lib/ruby/1.8/webrick/server.rb:82:in `start'
Rendering /opt/redmine_trunk/public/500.html (500 Internal Server Error)