Sha256: deb70f8370d89dd640828c0a4ab696a255e9e6bc3b30c9ca2cfcc87963c66d29

Contents?: true

Size: 342 Bytes

Versions: 26

Compression:

Stored size: 342 Bytes

Contents

class Freddy
  class MessageHandler
    def initialize(adapter, delivery)
      @adapter = adapter
      @delivery = delivery
    end

    def success(response = nil)
      @adapter.success(@delivery, response)
    end

    def error(response = {error: "Couldn't process message"})
      @adapter.error(@delivery, response)
    end
  end
end

Version data entries

26 entries across 26 versions & 2 rubygems

Version Path
freddy-0.6.0 lib/freddy/message_handler.rb
freddy-0.5.8 lib/freddy/message_handler.rb
freddy-0.5.7 lib/freddy/message_handler.rb
freddy-jruby-0.5.6 lib/freddy/message_handler.rb
freddy-0.5.6 lib/freddy/message_handler.rb
freddy-0.5.5 lib/freddy/message_handler.rb