We use rails version 2.3.5
This error has been reported in SO here
I tried the following:
- adding config.cache_class = true – the problem with this was that, the server had to be restarted every time a change was made to any controller. Also the server start time was too long
- adding unloadable to the middleware – no use
- adding config.middleware.use [middleware] to development.rb – no use
Is there a way to overcome this other than making development similar to production?
Edit
even tried adding config.middleware.use [middleware] to environment.rb. Well this behaved totally different. My error disappeared, but my middleware cracked. All it’s objects were nil..!
Found the answer.
this was not working previously for me because i was initializing this middle ware inside session_store too. So the same middle ware was executed twice with the second time all params with nil – Hence the nil problem.
Thank you rogerdpack for trying to help.!