minimongo: make idStringify behavior match comment

This commit is contained in:
David Greenspan
2013-07-10 04:11:00 -07:00
parent 7617d8931a
commit 4cd63ca370

View File

@@ -841,7 +841,7 @@ LocalCollection._idStringify = function (id) {
}
} else if (id === undefined) {
return '-';
} else if (typeof id === 'object') {
} else if (typeof id === 'object' && id !== null) {
throw new Error("Meteor does not currently support objects other than ObjectID as ids");
} else { // Numbers, true, false, null
return "~" + JSON.stringify(id);