亚洲在线久爱草,狠狠天天香蕉网,天天搞日日干久草,伊人亚洲日本欧美

為了賬號安全,請及時綁定郵箱和手機立即綁定
已解決430363個問題,去搜搜看,總會有你想問的

TypeError: Cannot read property '_id' of undefined建站攻略1期——編寫數據庫交互代碼出錯

TypeError: Cannot read property '_id' of undefined建站攻略1期——編寫數據庫交互代碼出錯

Micity 2016-05-04 10:10:00
TypeError: Cannot read property '_id' of undefined? ?at D:\imooc\app.js:78:25? ?at Layer.handle [as handle_request] (D:\imooc\node_modules\express\lib\router\layer.js:95:5)? ?at next (D:\imooc\node_modules\express\lib\router\route.js:131:13)? ?at Route.dispatch (D:\imooc\node_modules\express\lib\router\route.js:112:3)? ?at Layer.handle [as handle_request] (D:\imooc\node_modules\express\lib\router\layer.js:95:5)? ?at D:\imooc\node_modules\express\lib\router\index.js:277:22? ?at Function.process_params (D:\imooc\node_modules\express\lib\router\index.js:330:12)? ?at next (D:\imooc\node_modules\express\lib\router\index.js:271:10)? ?at serveStatic (D:\imooc\node_modules\express\node_modules\serve-static\index.js:74:16)? ?at Layer.handle [as handle_request] (D:\imooc\node_modules\express\lib\router\layer.js:95:5)? ?at trim_prefix (D:\imooc\node_modules\express\lib\router\index.js:312:13)? ?at D:\imooc\node_modules\express\lib\router\index.js:280:7? ?at Function.process_params (D:\imooc\node_modules\express\lib\router\index.js:330:12)? ?at next (D:\imooc\node_modules\express\lib\router\index.js:271:10)? ?at D:\imooc\node_modules\body-parser\lib\read.js:129:5? ?at invokeCallback (D:\imooc\node_modules\body-parser\node_modules\raw-body\index.js:262:16)
查看完整描述

4 回答

?
一頭飛奔的豬

TA貢獻9條經驗 獲得超17個贊

把app代碼po出來看看

查看完整回答
反對 回復 2016-05-11
?
風舞

TA貢獻6條經驗 獲得超1個贊

這個問題你可以查查數據庫里面有沒有記錄,按我的猜想,你這個估計數據庫記錄都沒新增成功

查看完整回答
反對 回復 2016-05-10
?
我的女神

TA貢獻1條經驗 獲得超0個贊


D:\imooc\app.js:78

你的app.js文件里面有一個屬性沒有賦值導致的。你仔細看看D:\imooc\app.js這個文件.

查看完整回答
反對 回復 2016-05-04
  • 4 回答
  • 0 關注
  • 2226 瀏覽

添加回答

舉報

0/150
提交
取消
微信客服

購課補貼
聯系客服咨詢優惠詳情

幫助反饋 APP下載

慕課網APP
您的移動學習伙伴

公眾號

掃描二維碼
關注慕課網微信公眾號