Functions cleanup for readability.