-
-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
object.isNew() cloud code #107
Comments
Sounds right. A change was made to support this in parse-cloud-express and a comparable change should be made here as well: https://github.com/ParsePlatform/parse-cloud-express/pull/5/files |
any plan when this will be fixed? |
Did you find a trick to get around this issue ? |
Looks like I tried numerous times injecting different weird things into the object, but either am encountering a mutation on reserved keys, or that the @andrewimm, any chance you can point me in the right direction here? How do we manage to handle Also, @gfosco, I don't think cloud-express handles |
I'm not entirely sure what the issue is with parse-server, since I imagine the object can't have an id before its first beforeSave, but I'm happy to help port any internal v8server logic. |
If it helps, I'm using this for now
|
@omairvaiyani Wouldn't that always return true until you update an object? |
Looks like our |
Looked into the source a bit now and found |
That also works. I actually just found out that we never were setting the objectId on a beforeSave hook for new objects, so my assumptions here are incorrect from the start. Working on a fix right now. |
Hi,
It looks like object.isNew() no longer returns true in the beforeSave function when a new object is created.
Please kindly take a look.
Thanks.
Sincerely,
Anthony
The text was updated successfully, but these errors were encountered: