Sha256: e53e0ac09c20eff2c2981e7bfdd8083aceb283fead514fdc800bfa3660daf350
Contents?: true
Size: 624 Bytes
Versions: 2
Compression:
Stored size: 624 Bytes
Contents
module CodeBuddy class Railtie < Rails::Railtie initializer "code_buddy.add_middleware" do |app| if app.config.action_dispatch.show_exceptions app.middleware.swap ActionDispatch::ShowExceptions, CodeBuddy::ShowExceptions app.middleware.use CodeBuddy::ShowApp end end end class ShowExceptions < ActionDispatch::ShowExceptions silence_warnings do ActionDispatch::ShowExceptions::RESCUES_TEMPLATE_PATH = File.join(File.dirname(__FILE__), 'templates') end def rescue_action_locally(request, exception) App.exception = exception super end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
code_buddy-0.0.4 | lib/code_buddy/rails3/railtie.rb |
code_buddy-0.0.3 | lib/code_buddy/rails3/railtie.rb |