Updated error messages and documentation