diff --git a/core/app/models/spree/gateway.rb b/core/app/models/spree/gateway.rb index 0c07c62a4a9..0d70295cdd3 100644 --- a/core/app/models/spree/gateway.rb +++ b/core/app/models/spree/gateway.rb @@ -11,11 +11,6 @@ def payment_source_class CreditCard end - # instantiates the selected gateway and configures with the options stored in the database - def self.current - super - end - def provider gateway_options = options gateway_options.delete :login if gateway_options.key?(:login) && gateway_options[:login].nil? diff --git a/sample/db/samples/payments.rb b/sample/db/samples/payments.rb index 5bac83a2beb..e5708d87599 100644 --- a/sample/db/samples/payments.rb +++ b/sample/db/samples/payments.rb @@ -1,13 +1,6 @@ # create payments based on the totals since they can't be known in YAML (quantities are random) method = Spree::PaymentMethod.where(name: 'Credit Card', active: true).first -# Hack the current method so we're able to return a gateway without a RAILS_ENV -Spree::Gateway.class_eval do - def self.current - Spree::Gateway::Bogus.new - end -end - # This table was previously called spree_creditcards, and older migrations # reference it as such. Make it explicit here that this table has been renamed. Spree::CreditCard.table_name = 'spree_credit_cards'