finished the validator