Skip to content

Commit

Permalink
fix adding middleware for rails 5.1.0 (#234)
Browse files Browse the repository at this point in the history
  • Loading branch information
bogdanRada authored and inossidabile committed Oct 6, 2017
1 parent cb3b34e commit 4f2a783
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions lib/wash_out/engine.rb
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@

module WashOut
class Engine < ::Rails::Engine
config.wash_out = ActiveSupport::OrderedOptions.new
initializer "wash_out.configuration" do |app|
if app.config.wash_out[:catch_xml_errors]
app.config.middleware.insert_after 'ActionDispatch::ShowExceptions', WashOut::Middleware
app.config.middleware.insert_after(ActionDispatch::ShowExceptions, WashOut::Middleware)
end
end

Expand Down

0 comments on commit 4f2a783

Please sign in to comment.