using pubsub in places