I am trying fetch records from mongoDB through mongoose

```
   router.route('/testaa')
     .get(function(req,res){
         fisSite.find(function(err, retVal) {
         var x = [];
         for(var i =0;i<retVal.length;i++){
         x.push(retVal[i].site);
        }
          res.json(x)
      });

   })

```

The above code is giving undefined values.

```
undefined
undefined
undefined
.....

```

Please help to run the for loop inside node.js so that i can use extract data from array.