make validation factory become better