-
-
Notifications
You must be signed in to change notification settings - Fork 4.8k
After Save User is not returning fields that I need #8387
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Thanks for opening this issue!
|
Could you add a complete step by step example code to demo the issue? With only the minimal code that's needed please. |
Hey @mtrezza of course! POST - /users
Expected return:
Actual return:
Code:
|
It's weird
but if i put the var without change It doesn't. ahah weird |
Related: We updated the save response so it would only be keys that are updated. But in the case of pendingOps, perhaps it could make sense to return the latest database value instead of the op. We also updated afterSave triggers so that a response could be returned to the client different to the one in the database. You can override the save response though by returning JSON, such as: Parse.Cloud.afterSave(Parse.User, async (request) => {
let user = request.object;
return user._toFullJSON();
}) |
Hey @dblythy thanks for adding the related links. But I'm changing the fullName and it isn't returning, and updatedAt was created too and isn't returning. And yes, this op is a problem for serialization, I opened other issue that I can't remove from the return the ops and It broke my serialization. :/ |
New Issue Checklist
Issue Description
After Save User is not returning fields that I need
the result will not come with this field, even if you put manually on AfterSave.
But if you put manually on AfterSave a property that doesn't exist on the database, it will return.
The login endpoint returns all the properties right.
Steps to reproduce
Create a property on Parse.User and Save a new Parse User filling this property.
Actual Outcome
Not returning properties like 'fullName'
Expected Outcome
Return properties that I need
Environment
Parse server Version 5.4.0 with MongoDB 5
Server
Database
Logs
The text was updated successfully, but these errors were encountered: