Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

git 部署后部分router报错 #42

Closed
lzx19951022 opened this issue Jun 17, 2020 · 6 comments
Closed

git 部署后部分router报错 #42

lzx19951022 opened this issue Jun 17, 2020 · 6 comments

Comments

@lzx19951022
Copy link

您好,我尝试在nas和电脑端克隆项目后使用npm start 命令运行,song/find 等几个get 都会报错,刚好就是需要这几个接口,我刚学node js,还比较小白,不知道怎么解决这个问题。。node版本是12.14.
image

@jsososo
Copy link
Owner

jsososo commented Jun 17, 2020 via email

@lzx19951022
Copy link
Author

完全保持了默认的设置,没有设置自己的账号,报错信息如下
(node:159516) UnhandledPromiseRejectionWarning: TypeError: Cannot read property 'data' of undefined at reqFun (E:\qqmusicapi\routes\song.js:146:22) at processTicksAndRejections (internal/process/task_queues.js:97:5) at async getUrls (E:\qqmusicapi\routes\song.js:152:5) (node:159516) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag --unhandled-rejections=strict(see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1) (node:159516) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

@jsososo
Copy link
Owner

jsososo commented Jun 17, 2020 via email

@lzx19951022
Copy link
Author

我可以通过fetch之类的post一个cookie就可以是咩

@jsososo
Copy link
Owner

jsososo commented Jun 17, 2020 via email

@lzx19951022
Copy link
Author

lzx19951022 commented Jun 17, 2020

按照你的提示post cookie之后不再报错了,感谢!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants