early stage of validation fn