made error messages more helpful