Fix getStudentDetails function