Updated comments and changed a function name