-
-
Notifications
You must be signed in to change notification settings - Fork 4.8k
Add original object to LiveQuery Events #5265
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
Add original object to LiveQuery Events #5265
Conversation
Codecov Report
@@ Coverage Diff @@
## master #5265 +/- ##
==========================================
+ Coverage 93.87% 93.91% +0.04%
==========================================
Files 123 123
Lines 8973 8975 +2
==========================================
+ Hits 8423 8429 +6
+ Misses 550 546 -4
Continue to review full report at Codecov.
|
src/LiveQuery/Client.js
Outdated
@@ -92,6 +96,12 @@ class Client { | |||
fields = this.subscriptionInfos.get(subscriptionId).fields; | |||
} | |||
response['object'] = this._toJSONWithFields(parseObjectJSON, fields); | |||
if (typeof parseOriginalObjectJSON !== 'undefined') { | |||
response['originalParseObject'] = this._toJSONWithFields( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We use ‘original’ in the before/after hooks. Can you have a look? Would be nice to preserve semantics
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
Thx! |
* Add original object to LiveQuery Events * change response original
Closes: #5233
No breaking changes, update will be needed on the JS SDK.
will be used for update and event subscriptions