Sha256: 5abb6d308ad7588cf601cfb429fb31f840accf23138f37294d4c747034b13f3f
Contents?: true
Size: 695 Bytes
Versions: 5
Compression:
Stored size: 695 Bytes
Contents
# This patch enables the exception handler to catch routing errors module ActionDispatch class ShowExceptions private def render_exception_with_template(env, exception) env = env.env if env.is_a?(ActionDispatch::Request) # Rails 5 passes in the whole request object if(RailsExceptionHandler.configuration.environments.include?(Rails.env.to_sym)) RailsExceptionHandler::Handler.new(env, exception).handle_exception else raise "RailsExceptionHandler: This patch should not have been loaded" end end alias_method :render_exception, :render_exception_with_template alias_method :template, :render_exception end end
Version data entries
5 entries across 5 versions & 1 rubygems