Changed registration endpoint code to store email.