RaddyTheBrand / 25.NodeJs-Express-EJS-MongoDB--Blog

https://express-mongodb-blog.vercel.app
MIT License
93 stars 47 forks source link

Error found. #3

Closed FluffPawz closed 11 months ago

FluffPawz commented 11 months ago

https://github.com/RaddyTheBrand/25.NodeJs-Express-EJS-MongoDB--Blog/blob/7c5810089e1f1779cb63bf8df5f6df4398326e12/server/routes/main.js#L26

Hello, I am new to coding but, I was following along on a tutorial and found an issue.

Where there is a depreciation countDocuments is suggested, in the written repository it is missing Post in front of it.

const count = await Post.countDocuments({ });

My code did not work until I fixed this.

RaddyTheBrand commented 11 months ago

Thank you!

FluffPawz commented 11 months ago

Your tutorials are awesome, I appreciate you!