[未解决]求教,nodeclub源码中配置`debug: false`,运行报错在这里,ubuntu,望各位大大帮忙看一下
发布于 9 年前 作者 ly525 4065 次预览 最后一次回复是 9 年前 来自 问答
node app.js启动项目报错,修改了config.js中的debug: false,尝试了好几次,没有解决方案,希望大大们帮忙看一下是哪里出了问题,感激不尽
报错如下
undefined:3
return function bound initialize(req, res, next) {
^^^^^^^^^^
SyntaxError: Unexpected identifier
at Function (native)
at wrapHandle (/home/lantern/Code/Project/GitHub/NodeJS_Learn/nodeclub/node_modules/newrelic/lib/instrumentation/express.js:273:19)
at Function.cls_wrapMiddlewareStack [as use] (/home/lantern/Code/Project/GitHub/NodeJS_Learn/nodeclub/node_modules/newrelic/lib/instrumentation/express.js:315:24)
at /home/lantern/Code/Project/GitHub/NodeJS_Learn/nodeclub/node_modules/express/lib/application.js:188:21
at Array.forEach (native)
at Function.use (/home/lantern/Code/Project/GitHub/NodeJS_Learn/nodeclub/node_modules/express/lib/application.js:185:7)
at Function.wrappedAppUse [as use] (/home/lantern/Code/Project/GitHub/NodeJS_Learn/nodeclub/node_modules/newrelic/lib/instrumentation/express.js:359:11)
at Object.<anonymous> (/home/lantern/Code/Project/GitHub/NodeJS_Learn/nodeclub/app.js:102:5)
at Module._compile (module.js:409:26)
at Object.Module._extensions..js (module.js:416:10)
at Module.load (module.js:343:32)
at Function.Module._load (module.js:300:12)
at Function.Module.runMain (module.js:441:10)
at startup (node.js:134:18)
at node.js:962:3
Program node app.js exited with code 1
3 回复
出错的app.js 部分代码如下
估计是配置错误
@i5ting 感谢您的回复 我把配置代码贴一下,不是很明白出错在哪里