Sha256: b8963b67a12607155dab18476ed4e579d758adf3bfc581d1fd7f66fb2a817241

Contents?: true

Size: 368 Bytes

Versions: 7

Compression:

Stored size: 368 Bytes

Contents

module Carload
  class Error < StandardError
    attr_reader :message
  end

  class UnmanagedModelError < Error
    def initialize data
      @message = I18n.t('carload.error.message.unmanaged_model', model: data)
    end
  end

  class UnsupportedError < Error
    def initialize data
      @message = "Carload does not support #{data} currently."
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
carload-0.4.1 lib/carload/exceptions.rb
carload-0.4.0 lib/carload/exceptions.rb
carload-0.3.0 lib/carload/exceptions.rb
carload-0.2.2 lib/carload/exceptions.rb
carload-0.2.1 lib/carload/exceptions.rb
carload-0.2.0 lib/carload/exceptions.rb
carload-0.1.0 lib/carload/exceptions.rb