I discovered that deserializeUser is not called if session was not found in a DB by express-mysql-session. Is it correct behavior?
Use case:
I'm using passport-local with session = true and with express-mysql-session as a session store. When session is ok (found by express-mysql-session in a DB) then deserializeUser is called all right. However if a session for some reason isn't found in a DB (eg. session cookie is manually deleted in a browser or a session row is manually deleted from DB) then deserializeUser doesn't get called. Why? Is it correct behavior?
I discovered that
deserializeUser
is not called if session was not found in a DB byexpress-mysql-session
. Is it correct behavior?Use case:
I'm using
passport-local
withsession = true
and withexpress-mysql-session
as a session store. When session is ok (found byexpress-mysql-session
in a DB) thendeserializeUser
is called all right. However if a session for some reason isn't found in a DB (eg. session cookie is manually deleted in a browser or a session row is manually deleted from DB) thendeserializeUser
doesn't get called. Why? Is it correct behavior?