Reorder some functions.