Fixed a typo, made error messages consistent.