[SERVER-21088] Change _massageObject string processing Created: 23/Oct/15 Updated: 13/Aug/16 Resolved: 09/Aug/16 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Shell |
| Affects Version/s: | None |
| Fix Version/s: | 3.3.11 |
| Type: | Task | Priority: | Major - P3 |
| Reporter: | Kevin Pulo | Assignee: | Matt Cotter |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Backwards Compatibility: | Fully Compatible |
| Sprint: | Build B (10/30/15), Build C (11/20/15), Platforms 2016-08-26 |
| Participants: |
| Description |
|
_massageObject (used by db.foo.find() and db.foo.remove()) converts a 24 char string into { _id: "..." }. Surely the intention behind the length == 24 check is to convert the string into the corresponding ObjectId()? src/mongo/shell/collection.js:134-158
|
| Comments |
| Comment by Githook User [ 09/Aug/16 ] | |||||||
|
Author: {u'username': u'Machyne', u'name': u'Matt Cotter', u'email': u'matt.cotter@mongodb.com'}Message: | |||||||
| Comment by Matt Cotter [ 09/Aug/16 ] | |||||||
I totally agree here. Also it's kind of a nice feature to have:
I don't see a good reason not to do this | |||||||
| Comment by Scott Hernandez (Inactive) [ 23/Oct/15 ] | |||||||
|
Maybe, but since it doesn't work that way now, it is probably better to just remove the string check all together. |