Skip to content

Commit

Permalink
Merge pull request #148 from hrtshu/move-mixin-include-to-bottom
Browse files Browse the repository at this point in the history
Move the inclusion of mixin to the bottom of the controller for customizable error handling
  • Loading branch information
pond authored Oct 22, 2024
2 parents cf6a159 + 2488878 commit f7bf0dd
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions app/controllers/scimitar/application_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,6 @@ class ApplicationController < ActionController::Base
before_action :add_mandatory_response_headers
before_action :authenticate

if Scimitar.engine_configuration.application_controller_mixin
include Scimitar.engine_configuration.application_controller_mixin
end

# =========================================================================
# PROTECTED INSTANCE METHODS
# =========================================================================
Expand Down Expand Up @@ -153,5 +149,8 @@ def authenticated?
return result
end

if Scimitar.engine_configuration.application_controller_mixin
include Scimitar.engine_configuration.application_controller_mixin
end
end
end

0 comments on commit f7bf0dd

Please sign in to comment.