error messages on edit and new