tansengming/stripe-rails

View on GitHub
lib/stripe/callbacks.rb

Summary

Maintainability
A
0 mins
Test Coverage
A
100%

Avoid rescuing the Exception class. Perhaps you meant to rescue StandardError?
Open

          rescue Exception => e
            ::Rails.logger.error e.message
            ::Rails.logger.error e.backtrace.join("\n")
Severity: Minor
Found in lib/stripe/callbacks.rb by rubocop

This cop checks for rescue blocks targeting the Exception class.

Example:

# bad

begin
  do_something
rescue Exception
  handle_exception
end

Example:

# good

begin
  do_something
rescue ArgumentError
  handle_exception
end

There are no issues that match your filters.

Category
Status