Sha256: 431092c02f10795d4d9a751811438e1bf475c5a2d08aa7e6bdd06170cc308bb9

Contents?: true

Size: 206 Bytes

Versions: 1

Compression:

Stored size: 206 Bytes

Contents

module Reactor::Subscribable
  extend ActiveSupport::Concern

  module ClassMethods
    def on_event(event, &callback)
      (Reactor::STATIC_SUBSCRIBERS[event.to_s] ||= []).push(callback)
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
reactor-0.3.1 lib/reactor/models/concerns/subscribable.rb