Fixed some coding errors.