Sha256: 0f158118c7b96b00b44bbb83ca1689b783c21e0c131137fa7d27cad59c61b9df

Contents?: true

Size: 336 Bytes

Versions: 4

Compression:

Stored size: 336 Bytes

Contents

module Workarea
  decorate Payment::Refund::CreditCard, with: :braintree do
    def complete!
      validate_reference!

      transaction.response = handle_active_merchant_errors do
        gateway.refund(
          transaction.amount.cents,
          transaction.reference.response.authorization
        )
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
workarea-braintree-1.1.2 app/models/workarea/payment/refund/credit_card.decorator
workarea-braintree-1.1.1 app/models/workarea/payment/refund/credit_card.decorator
workarea-braintree-1.1.0 app/models/workarea/payment/refund/credit_card.decorator
workarea-braintree-1.0.3 app/models/workarea/payment/refund/credit_card.decorator