You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fix "undefined property '__op'" in postgres update (#4541)
* Fix "undefined property '__op'" in postgres update
This causes a TypeError which becomes a regular Error,
before the update can be issued. (I think)
This happens when there is an object schema,
and there is also an unrelated field in originalUpdate
which is null or undefined.
e.g. when 'location' is a mandatory object in postgres,
and 'middleName' is an optional string,
PostgresStorageAdapter would throw when a query similar
to the below was performed:
(Object.keys(originalUpdate) would include "middleName" as a value of `k`)
query.set('location', {'country': 'US'})
query.set('middleName', undefined);
* Fix lint error
0 commit comments