adding a handler for push events