realm-js
realm-js copied to clipboard
Realm Web: User custom data needs to be EJSON deserialized
Goals & Expected Results
Users would expect custom data transmitted through the access token to be EJSON deserialized.
Actual Results
The data is not EJSON deserialized.
Steps to Reproduce
- Create a collection of documents and enable custom user data.
- Create a user and a matching document in the collection which contains an
undefined
value. - Authenticate the user and read the custom data.
- See how the undefined value is returned as {{{ "$undefined": true }}} (see https://docs.mongodb.com/manual/reference/mongodb-extended-json-v1/#undefined-type)
Code Sample
Version of Realm and Tooling
- Realm JS SDK Version: Realm Web 0.9.0
- Node or React Native: Web
- Client OS & Version: N/A
- Which debugger for React Native: N/A