Refactor some functions to use participant type