Sha256: e51ead19d4f6d5cb20eb1fc1ac91b7fd1edfe0f178048f898589704b28915472
Contents?: true
Size: 571 Bytes
Versions: 30
Compression:
Stored size: 571 Bytes
Contents
module Scrivito class ClientError < StandardError attr_reader :http_code, :backend_code def initialize(message, http_code: 412, backend_code: nil) @http_code = http_code @backend_code = backend_code super(message) end def ==(client_error) return false unless client_error.is_a?(ClientError) message == client_error.message && http_code == client_error.http_code && backend_code == client_error.backend_code end def as_json {message: message, backendCode: backend_code} end end end
Version data entries
30 entries across 30 versions & 1 rubygems