correcting error messages