搭建时出现错误了:express是4.12.1,node是0.12.0
依赖的包是: "mongodb": "1.4.15","express-session": "1.9.1","connect-mongo": "0.8.0","bson": "0.2.0","connect-flash": “0.1.1”
D:\node\microblog\node_modules\mongodb\lib\mongodb\connection\base.js:246
throw message;
^
TypeError: Cannot read property ‘length’ of undefined
at processResults (D:\node\microblog\node_modules\mongodb\lib\mongodb\db.js:
1603:31)
at D:\node\microblog\node_modules\mongodb\lib\mongodb\db.js:1641:20
at D:\node\microblog\node_modules\mongodb\lib\mongodb\db.js:1179:7
at D:\node\microblog\node_modules\mongodb\lib\mongodb\db.js:1912:9
at Server.Base._callHandler (D:\node\microblog\node_modules\mongodb\lib\mong
odb\connection\base.js:448:41)
at D:\node\microblog\node_modules\mongodb\lib\mongodb\connection\server.js:4
81:18
at MongoReply.parseBody (D:\node\microblog\node_modules\mongodb\lib\mongodb
responses\mongo_reply.js:68:5)
at null.<anonymous> (D:\node\microblog\node_modules\mongodb\lib\mongodb\conn
ection\server.js:439:20)
at emit (events.js:107:17)
at null.<anonymous> (D:\node\microblog\node_modules\mongodb\lib\mongodb\conn
ection\connection_pool.js:201:13)
2 回复