Added updateEmail test, rewrote how emails are updated