Sha256: 906571ef1d14f201df79d0acddb48ce58f83761ae281f00b62f25113ffe2ad81

Contents?: true

Size: 582 Bytes

Versions: 15

Compression:

Stored size: 582 Bytes

Contents

# frozen_string_literal: true

module SolidusBactracs
  class Error < StandardError; end

  class OrderNotPaidError < Error
    def initialize(order, *args)
      super("Order #{order.number} is not paid and capture_at_notification is false", *args)
    end
  end

  class ShipmentNotFoundError < Error
    def initialize(shipment_number, *args)
      super("Could not find shipment with number #{shipment_number}", *args)
    end
  end

  class PaymentError < Error
    def initialize(payment, *args)
      super("Could not process payment #{payment.id}", *args)
    end
  end
end

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
solidus_bactracs-4.0.1 lib/solidus_bactracs/errors.rb
solidus_bactracs-4.0.0 lib/solidus_bactracs/errors.rb
solidus_bactracs-3.5.2 lib/solidus_bactracs/errors.rb
solidus_bactracs-3.5.1 lib/solidus_bactracs/errors.rb
solidus_bactracs-3.5.0 lib/solidus_bactracs/errors.rb
solidus_bactracs-3.4.0 lib/solidus_bactracs/errors.rb
solidus_bactracs-3.3.2 lib/solidus_bactracs/errors.rb
solidus_bactracs-3.3.1 lib/solidus_bactracs/errors.rb
solidus_bactracs-3.3.0 lib/solidus_bactracs/errors.rb
solidus_bactracs-3.2.2 lib/solidus_bactracs/errors.rb
solidus_bactracs-3.2.1 lib/solidus_bactracs/errors.rb
solidus_bactracs-3.2.0 lib/solidus_bactracs/errors.rb
solidus_bactracs-3.1.2 lib/solidus_bactracs/errors.rb
solidus_bactracs-3.1.1 lib/solidus_bactracs/errors.rb
solidus_bactracs-3.1.0 lib/solidus_bactracs/errors.rb