cleaned up error setting methods