error messages implemented