Adds a proper base class for pubsub listeners.