fix error message on factory validation