Fix the function