📙 Possible incongruity on beforeLogin cloudCode documentation #701
Comments
|
@omairvaiyani could you take a look at this? |
|
@AugustoAmaral would you be able to describe the steps to reproduce the problem? |
|
@davimacedo I am using a custom authProvider and was trying to write an beforeLogin cloud function to update the roles based on authData info. |
|
The solution I have found, is update all roles on every afterSave, once every change of authData trigger afterSave function |
|
The docs aren't clear enough I guess The |
|
Got it, I'll create a PR and make an improvement to make it clear |
I was reading the parse cloud code docs on this part and saw :
The user is not available on the request object - the user has not yet been provided a session until after beforeLogin is successfully completedAnd after doing some tests, I realized that this information was incomplete, because I got this as answer:

Another information that can be considered relevant is that parse user object is not the original request one, but the one from database and I don't know why, and i think this cloudCode run beforeSave ParseUser.
I checked the code and couldn't really understand the code, since I'm a newbie🤣 . but I would like to know if what I perceived proceeds.
The text was updated successfully, but these errors were encountered: