Sha256: b210081cf50bd65846b26ee39d2721deb5a55b4758502ce5a12d1687b77ba34e
Contents?: true
Size: 650 Bytes
Versions: 15
Compression:
Stored size: 650 Bytes
Contents
# frozen_string_literal: true class Logster::Middleware::DebugExceptions < ActionDispatch::DebugExceptions private def log_error(request_or_env, wrapper) env = if Rails::VERSION::MAJOR > 4 request_or_env.env else request_or_env end exception = wrapper.exception Logster.config.current_context.call(env) do location = exception.backtrace[0] Logster.logger.add_with_opts( ::Logger::Severity::FATAL, "#{exception.class} (#{exception})\n#{location}", "web-exception", backtrace: exception.backtrace.join("\n"), env: env ) end end end
Version data entries
15 entries across 15 versions & 1 rubygems