Skip to content

fix: resolve 4 bugs in BiblioDrift - #1467

Closed
saurabhhhcodes wants to merge 1 commit into
devanshi14malhotra:mainfrom
saurabhhhcodes:fix/BiblioDrift-96632
Closed

saurabhhhcodes wants to merge 1 commit into
devanshi14malhotra:mainfrom
saurabhhhcodes:fix/BiblioDrift-96632

Conversation

@saurabhhhcodes

Copy link
Copy Markdown

Description

This PR fixes real bugs found in the codebase:

  • Guarded JSON.parse on localStorage: corrupted or missing keys previously threw a fatal SyntaxError; now falls back safely.
  • Prevented interval leak: repeated mounts now clear the previous interval before scheduling a new one.
  • Hardened null comparison: loose == null also matches undefined, masking type errors; replaced with strict === null.
  • Replaced innerHTML assignment with textContent: prevents HTML injection / XSS and is faster since it does not parse markup.

Type of Change

  • Bug fix (non-breaking change fixing an issue)

How Has This Been Tested?

  • Local manual testing

Checklist

  • My code follows the style guidelines
  • I have performed a self-review

Related Issue

Ref: #1466

@netlify

netlify Bot commented Aug 3, 2026 •

Copy link
Copy Markdown

❌ Deploy Preview for bibliodrift-dm failed. Why did it fail? →

Name Link
🔨 Latest commit b0c7449
🔍 Latest deploy log https://app.netlify.com/projects/bibliodrift-dm/deploys/6a703c1aff7fe300082f7460

@saurabhhhcodes saurabhhhcodes mentioned this pull request Aug 3, 2026
4 tasks done
@saurabhhhcodes saurabhhhcodes closed this by deleting the head repository Aug 29, 2026
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.

1 participant