Email confirmation not working.

Email confirmation does not work, instead it directs to a error page and
the account is created without confirmation.