Fixed some mistakes with comments in the functions