Express mongo session store

I am trying to use express-session-mongo module in one of our projects. The code is exactly the same as seen on https://github.com/mikkel/express-session-mongo but I get "Cannot read property 'BSON' of undefined" error when I launch the app. Is there a module I forgot to require?

Answers


express-session-mongo tries to use the native bson parser for mongodb and that needs to be compiled separately.

Compiling the native parser inside the express-session-mongo directory solved it for me:

cd node_modules/express-session-mongo
npm install mongodb --mongodb:native

Need Your Help

Aspose cell exception:om.ctc.wstx.sr.ValidatingStreamReader cannot be cast to com.ctc.wstx.sr.ValidatingStreamReader

java excel aspose aspose-cells

I am using Aspose.Cells (trial version) to parse a .xls (Excel) file for Java. But when I try to load the file, it throws the exception given below: