Sha256: 4be4941a09ff02c5c5e7051497c9251ff661420ea11d1d942548b2007a188743
Contents?: true
Size: 464 Bytes
Versions: 13
Compression:
Stored size: 464 Bytes
Contents
class PipeRpc::ErrorResponse; end module PipeRpc class Hub::Message::ErrorResponse < ErrorResponse def initialize(hub, body) @hub = hub super body end def to_error case @code when -32700 then MessageParseError.new(@data.fetch(:message)) when -32600 then InvalidMessageError.new(@data.fetch(:message)) else UnknownError.new(@data[:message]) end end def handle raise to_error end end end
Version data entries
13 entries across 13 versions & 1 rubygems