Skip to content

Commit

Permalink
Remove duplicate code in application_controller.rb
Browse files Browse the repository at this point in the history
Removing `rescue_from Pundit::NotAuthorizedError, with: :user_not_authorized` from line 25, because the exact statement also exists on line 20 of this same file.
  • Loading branch information
aaronskiba committed Apr 30, 2024
1 parent 86504f6 commit 185e8aa
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions app/controllers/application_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,6 @@ class ApplicationController < ActionController::Base
# When we are in production reroute Record Not Found errors to the branded 404 page
rescue_from ActiveRecord::RecordNotFound, with: :render_not_found

rescue_from Pundit::NotAuthorizedError, with: :user_not_authorized

private

def current_org
Expand Down

0 comments on commit 185e8aa

Please sign in to comment.