Regular expression objects are stateful, and the global flag interferes badly with the expression. A valid call can cause it to act like a flip flop instead of a stateless test.
ILAG only works on HSes that allow registering without an email
address, so whenever we redirect to the ILAG flow, check what
registration flows the server supports, and if it doesn't offer one
that's ILAG-compatible, prompt the user to go through the full
registration process instead.
This doesn't change all the entry points into ILAG, I'll do that
in a separate commit.