I have a function that should update a token, based on an user\'s email. The thing is, the following code returns a token even if there isn\'t any document with the specifie