added general validation

added general validation