fix the functions loading