diff --git a/lib/aethyr/core/event.rb b/lib/aethyr/core/event.rb index 21cfb3501ee5ec45646f21c5ca1fe0ce1c3a2b0d..376d7820cd75a05409fe2d003609752e04a6dae8 100644 --- a/lib/aethyr/core/event.rb +++ b/lib/aethyr/core/event.rb @@ -61,8 +61,9 @@ class Event < OpenStruct #name must be a symbol which is the same as the module which handles the event. # #An optional hash can be passed in as well to define attributes. - def initialize(**args) - super args + def initialize(type, **kwargs) + kwargs[:type] = type + super kwargs end #Retrieve an attribute.