Open
Description
New Issue Checklist
- I am not disclosing a vulnerability.
- I am not just asking a question.
- I have searched through existing issues.
- I can reproduce the issue with the latest version of Parse Server.
Issue Description
-A user is being detected as new when he isn't.
-authData field being deleted for unknown reasons.
Steps to reproduce
Add the following code to the cloud code and try to login using Facebook, Twitter, or Google.
Parse.Cloud.afterSave(Parse.User, async (request) => {
if (!request.original) {
"need to perform some actions here when a user has just signed up"
}
});
Actual Outcome
This issue leads to performing unwanted actions over a non new user.
After a user performs a login/signup through Facebook, Twitter, or Google, the user is always being detected as a new user in afterSave.
When checking again in the database you can see that the same user has just logged in and it's not a new one,
Noticed also something with the authData field, when testing login with different methods the authData is being erased(doesn't happen all the time).
Expected Outcome
Not detect a user as a new one when he isn't.
Environment
Server
- Parse Server version:
parse-server@5.0.0-alpha.3
- Operating system:
Windows 10
- Local or remote host (AWS, Azure, Google Cloud, Heroku, Digital Ocean, etc):
Local
Database
- System (MongoDB or Postgres):
MongoDB
- Database version:
FILL_THIS_OUT
- Local or remote host (MongoDB Atlas, mLab, AWS, Azure, Google Cloud, etc):
MongoDB Atlas
Client
- SDK (iOS, Android, JavaScript, PHP, Unity, etc):
Android
- SDK version:
1.26.0