Why does it appear?
This error indicates that your server has crashed
Why did it collapse?
- Because you triggered a bug when executing a function, that is, the code is wrong, it naturally collapsed
Where did it collapse?
-
When you run the project, you definitely need to run the node service. You open the cmd panel that runs the node service, and you will see an error message.
Like my one, the error message is an internal error in other files I call.Generally, your server source program will not make mistakes, because if you make mistakes, you will not be able to run it. The place where you make mistakes is when you call other files.
Resolve errors
Find the corresponding wrong place he reported
Verify code correctness
Everyone's code is different, you can only modify it here
I show my mistake:
- My code here is sloppy when calling the database
- The correct one should be:
db.collection(collName).findOne(whereObj,cb)