Moved middleware configuration to init.rb
Merge commit '98525f289f87067989dede351d84fbda819bf26e'