Skip to content

Fix WEBSITE-4F: Teammates useSession import - #387

Open
seer-by-sentry[bot] wants to merge 1 commit into
mainfrom
seer/fix/website-4f-teammates-usesession-import
Open

Fix WEBSITE-4F: Teammates useSession import#387
seer-by-sentry[bot] wants to merge 1 commit into
mainfrom
seer/fix/website-4f-teammates-usesession-import

Conversation

@seer-by-sentry

Copy link
Copy Markdown

This PR addresses issue WEBSITE-4F, a TypeError: Cannot read properties of undefined (reading 'data') occurring on profile pages (/profile/:destinyMembershipId).

The root cause was identified in src/components/profile/raids/Teammates.tsx, where useSession was incorrectly imported directly from "next-auth/react". This caused session to be undefined when the session context was missing, leading to the TypeError when attempting to access session.data.

The fix involves changing the import statement in Teammates.tsx to use the application's custom useSession wrapper ("~/hooks/app/useSession"). This wrapper safely handles missing session contexts by returning a default object ({ data: null, status: "loading" }), preventing the TypeError.

Fixes WEBSITE-4F

@vercel

vercel Bot commented Jul 13, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
raid-hub Ready Ready Preview Jul 13, 2026 11:01pm

Request Review

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants