C:\Users\Nick\Desktop\turntablefm\Bots\Super Bot>node bot.js node.js:201 throw e; // process.nextTick error, or 'error' event on first tick ^ Error: Cannot find module 'mongoose' at Function._resolveFilename (module.js:334:11) at Function._load (module.js:279:25) at Module.require (module.js:357:17) at require (module.js:368:17) at Object.<anonymous> (C:\Users\Nick\Desktop\turntablefm\Bots\Super Bot\db.j s:1:78) at Module._compile (module.js:432:26) at Object..js (module.js:450:10) at Module.load (module.js:351:31) at Function._load (module.js:310:12) at Module.require (module.js:357:17)
I already installed it using npm install and I tried reinstalling but that didn't work any ideas?
Mongoose is a MongoDB ODM (Object database Modelling) that is used to translate the code and its representation from MongoDB to the Node. js server. Advantages of Mongoose module: Collection validation of the MongoDB database can be done easily.
If you want to confirm that you have installed mongoose you can check in the node_modules folder. This is the folder where npm installs everything. There is typically a folder for every package installed. You will find a mongoose directory if you have installed mongoose correctly.
try installing mongoose using this command:
npm install mongoose
do not use the -g switch.
BTW: I ran command prompt in admin mode. Reference
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With