fixed custom validator