Class: Cura::Event::Middleware::Dispatch

Inherits:
Base
  • Object
show all
Defined in:
lib/cura/event/middleware/dispatch.rb

Overview

Adds the event to the dispatch queue. Should be the very last middleware in the chain.

Instance Method Summary collapse

Instance Method Details

#call(options = {}) ⇒ Object

Add the event to the dispatch queue.

Parameters:

  • options (#to_h) (defaults to: {})

Options Hash (options):



11
12
13
# File 'lib/cura/event/middleware/dispatch.rb', line 11

def call(options={})
  options[:dispatch_queue] << options[:event]
end