Sha256: 49f195fd1d359a58798f98fedd4f1d5198c2dd00b4b3e22c1f842125ed07d94b

Contents?: true

Size: 336 Bytes

Versions: 6

Compression:

Stored size: 336 Bytes

Contents

module OmiseGO
  class ErrorHandler
    ERRORS = {
      nil_id: {
        code: 'user:nil_id',
        description: 'The given ID was nil.'
      }
    }.freeze

    class << self
      def handle(code)
        Error.new(code: ERRORS[code][:code],
                  description: ERRORS[code][:description])
      end
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
omisego-0.12.0 lib/omisego/error_handler.rb
omisego-0.11.0 lib/omisego/error_handler.rb
omisego-0.10.0 lib/omisego/error_handler.rb
omisego-0.9.6 lib/omisego/error_handler.rb
omisego-0.9.5 lib/omisego/error_handler.rb
omisego-0.9.4 lib/omisego/error_handler.rb