add edit errors and validations