Skip to content

fix: prevent crash when pullRequest is null in collaborators fetch#2

Open
devMonkRahul wants to merge 1 commit intowbfoss:mainfrom
devMonkRahul:feature/bugFixIssue1
Open

fix: prevent crash when pullRequest is null in collaborators fetch#2
devMonkRahul wants to merge 1 commit intowbfoss:mainfrom
devMonkRahul:feature/bugFixIssue1

Conversation

@devMonkRahul
Copy link
Copy Markdown

🐛 Fix: Cannot read properties of null (reading 'pullRequest') when loading collaborators

📌 Related Issue

Closes #1


📝 Summary

This PR fixes a runtime error that occurs when fetching collaborators. The application was attempting to access pullRequest on a null object, causing a crash and preventing the dashboard from loading properly.


🔍 Root Cause

The issue was caused by missing null/undefined checks before accessing the pullRequest property in the collaborators fetching logic.


✅ Fix Implemented

  • Added proper null/undefined checks before accessing pullRequest
  • Improved handling of API responses to avoid unexpected crashes
  • Ensured the UI remains stable even when data is missing or delayed

🧪 Testing

  • Reproduced the issue locally and verified the fix
  • Ran the following commands successfully:
    npm run test
    npm run build
    
    
    
image

@vercel
Copy link
Copy Markdown

vercel bot commented Mar 22, 2026

@devMonkRahul is attempting to deploy a commit to the wbfoss' projects Team on Vercel.

A member of the Team first needs to authorize it.

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.

Bug: Cannot read properties of null (reading 'pullRequest') when loading collaborators

1 participant