diff --git a/types/mongodb/mongodb-tests.ts b/types/mongodb/mongodb-tests.ts index e4c7f3bd8a..549537812d 100644 --- a/types/mongodb/mongodb-tests.ts +++ b/types/mongodb/mongodb-tests.ts @@ -85,7 +85,7 @@ let options = { let cursor: mongodb.Cursor = collection.find({color: 'black'}) cursor.toArray(function (err,r) { r[0].cost} ); cursor.forEach(function (bag ) { bag.color }, () => {}); - collection.findOne({ color: 'white' }).then(() => { }) + collection.findOne({ color: 'white' }).then(b => { let _b:bag = b; }) collection.findOne({ color: 'white' }).then(b => { b.cost; }) } {