Skip to content
This repository has been archived by the owner on Feb 3, 2022. It is now read-only.

EJSON.parse return undefined when json contains fields with null value #2

Closed
avivr opened this issue May 24, 2017 · 0 comments
Closed

Comments

@avivr
Copy link

avivr commented May 24, 2017

const ExtJSONModule = require("mongodb-extjson");
const EJSON = new ExtJSONModule();

const jsonString = `{"result":[{"_id":{"$oid":"591801a468f9e7024b623939"},"emptyField":null}]}`;
const obj = EJSON.parse(jsonString, { strict: false });
console.log(obj); // undefined
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant