changed Validation logic to criteria