Refactory: converting functions to void.