Fix login error

Caused by attempting to find user through checking email against the non-existent in MongoDB id field.