minor fixes with error messages