-
Notifications
You must be signed in to change notification settings - Fork 7
Open
Description
I have a project with sequelize and enabled timestamps by default.
This means that for all models I have fields createdAt and updatedAt.
Also, these fields are automatically added to each generated by sequelize SQL query.
Because of this get session method SequelizeSessionStore.get which uses Session.findByPk is generating next query:
Executing (default): SELECT `session_id`, `expires`, `data`, `createdAt`, `updatedAt` FROM `Sessions` AS `Session` WHERE `Session`.`session_id` = 'pprihgrAbXvDftF6y5IL6OEDYiXe8z_l';
To ommit that easily can be added { timestamps: false } to Sessions definition.
Previously I was using express-mysql-session, but it create an issue with running tests with an hanging db connection after test run. So decided to switch to your package to reuse the same connection which sequelize provides. And currently can not use this library, cuz already there sessions table without timestamps fields.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels