Pass full update object in all hooks ! #1007
geminigeek
started this conversation in
Feature Requests & Ideas
Replies: 1 comment 1 reply
-
There is one PR open about passing the previous object state in the |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
hi,
i want to suggest an "originalUpdateObject" , similar to the data key which is passed to beforeValidate hook and afterChange field hook , to be made available to all hooks down the line. this can be used to further process sub / nested objects after the main object is updated or created.
currently we can access req.body while the update/create query is running with an express request, but while we are in local api , we don't have access to req.body?
mostly i will be using this new key in afterChange collection hook
this feature will be very helpful if we send a large object with many nested objects and arrays to save and update.
thanks for reading
Dee
Beta Was this translation helpful? Give feedback.
All reactions