From f1a4b4e228ed077692c5bbe6af094308b87c2874 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Mon, 29 Apr 2024 08:32:06 -0400 Subject: [PATCH] Disable `Style/SignalException` cop (#30064) --- .rubocop_todo.yml | 8 -------- lib/devise/strategies/two_factor_ldap_authenticatable.rb | 2 +- lib/devise/strategies/two_factor_pam_authenticatable.rb | 2 +- 3 files changed, 2 insertions(+), 10 deletions(-) diff --git a/.rubocop_todo.yml b/.rubocop_todo.yml index c2826d718c7..e656578149b 100644 --- a/.rubocop_todo.yml +++ b/.rubocop_todo.yml @@ -205,14 +205,6 @@ Style/SafeNavigation: Exclude: - 'app/models/concerns/account/finder_concern.rb' -# This cop supports safe autocorrection (--autocorrect). -# Configuration parameters: EnforcedStyle. -# SupportedStyles: only_raise, only_fail, semantic -Style/SignalException: - Exclude: - - 'lib/devise/strategies/two_factor_ldap_authenticatable.rb' - - 'lib/devise/strategies/two_factor_pam_authenticatable.rb' - # This cop supports unsafe autocorrection (--autocorrect-all). # Configuration parameters: Mode. Style/StringConcatenation: diff --git a/lib/devise/strategies/two_factor_ldap_authenticatable.rb b/lib/devise/strategies/two_factor_ldap_authenticatable.rb index 065aa2de88a..c8258deb16d 100644 --- a/lib/devise/strategies/two_factor_ldap_authenticatable.rb +++ b/lib/devise/strategies/two_factor_ldap_authenticatable.rb @@ -16,7 +16,7 @@ module Devise if resource && !resource.otp_required_for_login? success!(resource) else - fail(:invalid) + fail(:invalid) # rubocop:disable Style/SignalException -- method is from Warden::Strategies::Base end end diff --git a/lib/devise/strategies/two_factor_pam_authenticatable.rb b/lib/devise/strategies/two_factor_pam_authenticatable.rb index 5ce723b331d..a9db1b6a29f 100644 --- a/lib/devise/strategies/two_factor_pam_authenticatable.rb +++ b/lib/devise/strategies/two_factor_pam_authenticatable.rb @@ -15,7 +15,7 @@ module Devise if resource && !resource.otp_required_for_login? success!(resource) else - fail(:invalid) + fail(:invalid) # rubocop:disable Style/SignalException -- method is from Warden::Strategies::Base end end