Corrected a function name. Added some comments.