fixing up regex validator