lib/emittance/registration.rb in emittance-0.0.2 vs lib/emittance/registration.rb in emittance-0.0.3

- old
+ new

@@ -1,13 +1,13 @@ # frozen_string_literal: true module Emittance # @private class Registration - attr_reader :identifier + attr_reader :event_klass - def initialize(identifier, &callback) - @identifier = identifier + def initialize(event_klass, &callback) + @event_klass = event_klass @callback = callback end def call(event) @callback.call event