-
Notifications
You must be signed in to change notification settings - Fork 31
Open
Labels
Description
Problem
The app has sign in and sign up but no way for users to log out. Once logged in, users can't sign out of their account.
What's Missing?
- No logout API route
- No logout button in UI
- No session cleanup mechanism
Proposed Solution
Add a complete logout flow:
-
Create logout API endpoint (
/api/auth/logout)- Delete session from database
- Clear session cookie
- Return success response
-
Add logout button in header/dashboard
- Show when user is logged in
- Call logout API
- Redirect to home page
Implementation Details
New file: src/app/api/auth/logout/route.ts
// Delete session from DB and clear cookieReactions are currently unavailable
Metadata
Metadata
Assignees
Labels
Projects
Status
In progress