The current Rack middleware implementation does not always assign a new parser instance to the environment.
If the Rack server reuses the same "env" instance between requests (e.g., Unicorn) this can cause parsers created for previous requests to incorrectly be re-used for the current request.
handle reuse of the env instance between requests (Unicorn compatibil…
I spent an hour or so trying to figure out what the heck was going on before seeing this request.
Can someone confirm this fixed their problem? I have tried using it and am still seeing what appears to be unicorn reusing previous ACCEPT_LANGUAGE headers.
@drewB This did work for me at the time but I forget the exact circumstances. I'm assuming you didn't forget to reboot your rails/unicorn env after applying this patch?
thanks @seedifferently. I did remember to reboot. I wonder if it is a conflict with #19 which I also applied. I will look into it some more.
Fixes for me.
@iain made me a maintainer, so I'll be resolving all outstanding issues today, and hopefully release a new version :)