From f0d5c70b1e07d4a567aa9507d76afff090a3ee1d Mon Sep 17 00:00:00 2001 From: Gregor MacDougall Date: Wed, 24 Apr 2019 06:30:44 -0400 Subject: [PATCH] Simplify Solidus Dependencies This moves the solidus dependency imports to only directly import solidus_core and solidus_api through the gemspec. --- config/initializers/braintree.rb | 4 +++- solidus_paypal_braintree.gemspec | 3 ++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/config/initializers/braintree.rb b/config/initializers/braintree.rb index d5b7effe..3cd773ae 100644 --- a/config/initializers/braintree.rb +++ b/config/initializers/braintree.rb @@ -1 +1,3 @@ -Spree::Admin::PaymentsController.helper :braintree_admin +if SolidusSupport.backend_available? + Spree::Admin::PaymentsController.helper :braintree_admin +end diff --git a/solidus_paypal_braintree.gemspec b/solidus_paypal_braintree.gemspec index a5c38710..100a0554 100644 --- a/solidus_paypal_braintree.gemspec +++ b/solidus_paypal_braintree.gemspec @@ -17,7 +17,8 @@ Gem::Specification.new do |s| s.files = Dir["{app,config,db,lib}/**/*", 'LICENSE', 'Rakefile', 'README.md'] s.test_files = Dir['test/**/*'] - s.add_dependency "solidus", ['>= 1.0', '< 3'] + s.add_dependency "solidus_api", ['>= 1.0', '< 3'] + s.add_dependency "solidus_core", ['>= 1.0', '< 3'] s.add_dependency "solidus_support", '>= 0.1.3' s.add_dependency "braintree", '~> 2.65' s.add_dependency 'activemerchant', '~> 1.48'