AOSSIE-Org / AOSSIE-Org/DebateAI

Unsafe JSON Parsing Leads to entire application will crash (White Screen of Death).

Open
#300 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
84
Forks
198
Avg merge
2d 19h
Merged PRs (30d)
30

Description

**Location**: `frontend/src/Pages/DebateRoom.tsx `

- Issue: JSON.parse(savedState) is used on data from localStorage without a try-catch block.

- Fix: Wrap JSON.parse in a try-catch block and fallback to default state if parsing fails.

**Why: If local storage data is corrupted or the schema changes, the entire application will crash (White Screen of Death).
fix this issue**

@bhavik-mangla Please checkout this solution #299

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.