added validator function to formhandler, now testing it