mirror of
https://github.com/mongodb/mongo.git
synced 2024-12-01 09:32:32 +01:00
handle null return from reduce
This commit is contained in:
parent
e6069e40d9
commit
8269a86c5f
@ -40,7 +40,7 @@ MR.doReduce = function( useDB ){
|
||||
}
|
||||
|
||||
var r = $reduce( data.key , data.values );
|
||||
if ( r.length && r[0] ){
|
||||
if ( r && r.length && r[0] ){
|
||||
data.values = r;
|
||||
}
|
||||
else{
|
||||
|
Loading…
Reference in New Issue
Block a user