Skip to content

Commit a1ca631

Browse files
authored
fix(collection): don't treat ObjectId as object for mapReduce scope
See https://travis-ci.org/Automattic/mongoose/jobs/155174111
1 parent 82fd87c commit a1ca631

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/collection.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3088,7 +3088,7 @@ define.classMethod('group', {callback: true, promise:true});
30883088
* @ignore
30893089
*/
30903090
function processScope (scope) {
3091-
if(!isObject(scope)) {
3091+
if(!isObject(scope) || scope instanceof ObjectID) {
30923092
return scope;
30933093
}
30943094

0 commit comments

Comments
 (0)