Reorganizing the functions.