-
Type: Improvement
-
Resolution: Won't Fix
-
Priority: Major - P3
-
None
-
Affects Version/s: 2.0.4, 2.1.0, 2.2.0
-
Component/s: JavaScript
-
Labels:
This method should return the hex string representation of the ObjectId.
var o = new ObjectId() o.valueOf() //yields either ObjectId("4f74646d2a0368211d9a16bc") or "4f74646d2a0368211d9a16bc" depending on the version o.toString() //the opposite representation from valueOf() o.toHexString() // should get only the string - "4f74646d2a0368211d9a16bc"