refactor to allow anonymous user to view events