Fixed typo in comment.
Added 'const' to a function variable to indicate that it is not being changed.