modified the way set inherits from the EventEmitter to avoid deprecated calls