Skip to content

Commit

Permalink
Merge pull request #208 from solidusio/elia/deface-overrides-autoload
Browse files Browse the repository at this point in the history
Don't try to autoload the deface overrides folder
  • Loading branch information
elia authored Dec 22, 2023
2 parents 2f93111 + b699238 commit 4b102ba
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 1 deletion.
3 changes: 3 additions & 0 deletions .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,3 +69,6 @@ Rails/Inquiry:
Enabled: true
Exclude:
- spec/lib/solidus_paypal_commerce_platform/configuration_spec.rb

Layout/LineLength:
Enabled: false
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ def alert_no_classic_frontend_support
private

def solidus_mount_point
mount_point = Spree::Core::Engine.routes.find_script_name({})
mount_point = ::Spree::Core::Engine.routes.find_script_name({})
mount_point += "/" unless mount_point.end_with?("/")
mount_point
end
Expand Down
4 changes: 4 additions & 0 deletions lib/solidus_paypal_commerce_platform/engine.rb
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,10 @@ class Engine < Rails::Engine

engine_name 'solidus_paypal_commerce_platform'

initializer "solidus_paypal_commerce_platform.zeitwerk_ignore_deface_overrides", before: :eager_load! do |app|
app.autoloaders.main.ignore(root.join('app/overrides'))
end

initializer "solidus_paypal_commerce_platform.add_payment_method", after: "spree.register.payment_methods" do |app|
app.config.to_prepare do
app.config.spree.payment_methods << SolidusPaypalCommercePlatform::PaymentMethod
Expand Down

0 comments on commit 4b102ba

Please sign in to comment.