better support different form types during validation
Merge pull request #1794 from dimagi/user_reg_fix

better support different form types during validation