changed some code, but seems like the registration code is still buggy. it still doesn't catch multiple instances of the same email, and it doesn't get the id of the user