Skip to main content
The 2024 Developer Survey results are live! See the results

All Questions

Tagged with
0 votes
0 answers
18 views

Why does clearing all sessions make my NestJS app unresponsive?

I have a NestJS app, with a special Admin route I want to be able to call to clear out all user sessions (for example: after we deploy a new version of the application so we can kick everyone out). I ...
Chris Barr's user avatar
0 votes
0 answers
18 views

Session Cart Resets After First Product Addition in Express.js Application

I'm building an online store application using Express.js, and I'm having trouble with session persistence. The cart works fine the first time I add a product, but if I add another product or make any ...
Saleh Enab's user avatar
0 votes
1 answer
34 views

Session not persisting after redirect during Google OAuth 2.0 flow

I have been working on this bug for over 20 hours now, I can break it down in detail but can't solve it, so any help would be greatly appreciated. Currently Req.user and req.session are not persisting ...
Drail's user avatar
  • 1
0 votes
1 answer
31 views

Deleted user remains logged in despite account deletion

I'm encountering an issue where users remain logged in even after their accounts have been deleted by an admin in my Express.js application using MongoDB for user data storage. When an admin deletes a ...
prajitha k's user avatar
0 votes
1 answer
28 views

What If Session Expires While User Is Still On The Website

Suppose that there are 5 minutes left for the session to expire when user enters the website.Every action that user will make after 5 minutes will be rejected by server if it requires you to login and ...
Tunahan Keklik's user avatar
0 votes
1 answer
30 views

Issue with back button navigation after login in Node.js Express using sessions and cookies

I've implemented a basic login system using session and cookies in Node.js Express. After successful login, users are redirected to /home to see a welcome page. However, when users click the browser's ...
prajitha k's user avatar
1 vote
0 answers
27 views

express-session not working in deployement but working in development

I worked on a MERN project and everything was going well in development(local) mode. When i hosted my code on vercel i noticed that session are not working properly. my mentor suggested to create a ...
Vishnu Shouryan Reddy Hanmandl's user avatar
0 votes
0 answers
41 views

req.session.userId returns undefined

Please guys come to my aid. I have battling this issue for weeks now. I am currently taking the Ben Awad Full-Stack course and I'm having trouble with the express-session part. Whenever I try to ...
Nzubechukwu Ukagha's user avatar
0 votes
0 answers
26 views

Express JS connect-flash requires manual additional page reload

My flash messages seem to require an additional manual reload of the page for them to appear. Here's an example of how I'm using it: if (password.length < 12) { req.flash('error', '...
Petter Thowsen's user avatar
1 vote
0 answers
15 views

passport serialize/deserialize user google login problem

why if a user logged in with google makes a post to secrets the req.user only includes the googleId but when its a normal user it contains all the object stored in the db im trying to use the objectId ...
brazilclouds's user avatar
0 votes
1 answer
74 views

Express-session store not deleting session when using req.session.destroy()

Using express-session and connect-mongodb for session based authentication (or trying to at least). I have a logout route that is calling req.session.destroy(), I have the unset property set to "...
Matthew DeFusco's user avatar
0 votes
0 answers
16 views

"Remember Me" functionality usng PassportJS with express-session and connect-redis not working on browser restart

passport.use( 'local', new LocalStrategy( strategyOptions, async ( req: Request, email: string, password: string, done: (error: any, user?: any, options?: ...
PirateApp's user avatar
  • 5,933
0 votes
0 answers
38 views

Session doesn't show value on changing routes

Express session doesn't show value on changing routes. Here in '/login' route it shows req.session.user data, but in '/connect' it shows req.session.user is undefined Here is the code import express ...
GayalMelappilly's user avatar
0 votes
0 answers
26 views

I got a error called TypeError: Class constructor MongoStore cannot be invoked without 'new'

I am currently building a Node, Express, Passport.js WebApp called StoryBooks following a Youtube tutorial. Problem occurs in the session part. I'm trying to store the session in Mongo. //Sessions ...
Ayomal Weerasinghe's user avatar
0 votes
0 answers
31 views

Session Cookie Not Persisting in Browser on Fetch/Axios Request with Express, Passport, and NextJs

I've been working on an authentication flow using Express, Passport, and Redis for session management on the backend, with a React (Next.js) frontend. The sessions are correctly created and stored in ...
Anas AitZouinet's user avatar

15 30 50 per page
1
2 3 4 5
91