Alex,
Please add the next code:
pre
console.log("where string is:");
console.log(JSON.stringify(whereObject));
/pre
before code:
pre
return JSON.stringify(whereObject);
/pre
Run your application and you will get "where" string from console.
Try to understand what is wrong with it.
It should be something like this:
pre
code
{"_id": {$in: ["52fe1b5fe4b0a25c11c899df", "52fe1b6fe4b0a25c11c899e0"]} }
/code
/pre
If you have a similar string - please be sure ids in this string are exists in database.
If it doesn't helps please share your DB with us and write your "where" string.