We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 305f289 commit 861d461Copy full SHA for 861d461
1 file changed
app/controllers/api/v1/base_controller.rb
@@ -42,11 +42,12 @@ class BaseController < ApplicationController
42
# Add trial warning headers to all responses
43
after_action :add_trial_warning_headers, if: -> { current_organization.present? }
44
45
+ rescue_from StandardError, with: :render_internal_error
46
rescue_from ActiveRecord::RecordNotFound, with: :render_not_found
47
+ rescue_from ActiveRecord::StatementInvalid, with: :render_not_found
48
rescue_from ActiveRecord::RecordInvalid, with: :render_validation_errors
49
rescue_from ActionController::ParameterMissing, with: :render_parameter_missing
50
rescue_from Pundit::NotAuthorizedError, with: :render_forbidden_policy
- rescue_from StandardError, with: :render_internal_error
51
52
protected
53
0 commit comments