Closed tafkanator closed 5 years ago
Thanks for letting me know. The implementation I originally based this on, doesn't include it, so I assumed it's not a standard. I'll update it soon.
Implemented it here: https://github.com/Mrtenz/typeorm-store/tree/remove-expired-sessions, could you check if everything works as expected?
Thank You for the fast response. Tested on my codebase. It is working fine now.
Thanks for testing! I published typeorm-store@1.2.0
to npm.
One note, You should update readme about adding new option parameters
there is no code that deletes expired sessions from database. It seems that some other stores implement interval based mechanism to delete expired sessions periodically from database
sequelize example: https://github.com/mweibel/connect-session-sequelize/blob/master/lib/connect-session-sequelize.js#L152-L173
mysql example: https://github.com/chill117/express-mysql-session/blob/master/index.js#L429-L445