solving validation errors