fixed problem with then catch chain (Promise)...

This commit is contained in:
Paolo Arena
2019-02-12 19:10:58 +01:00
parent 71132b9a57
commit ea06079878
4 changed files with 57 additions and 39 deletions

View File

@@ -102,7 +102,7 @@ UserSchema.methods.generateAuthToken = function (req) {
return user.save()
.then(() => {
console.log("TOKEN CREATO IN LOGIN : " + token)
console.log("TOKEN CREATO IN LOGIN : " + token);
return token;
})
.catch(err => {