Skip to content

fix: resolve 4 bugs in GameHub - #487

Open
saurabhhhcodes wants to merge 1 commit into
kaifansariw:mainfrom
saurabhhhcodes:fix/GameHub-62626
Open

fix: resolve 4 bugs in GameHub#487
saurabhhhcodes wants to merge 1 commit into
kaifansariw:mainfrom
saurabhhhcodes:fix/GameHub-62626

Conversation

@saurabhhhcodes

Copy link
Copy Markdown

Description

This PR fixes real bugs found in the codebase:

  • Added explicit radix to parseInt: without 10, strings like '0x1F' or '08' parse in unintended bases.
  • Replaced innerHTML assignment with textContent: prevents HTML injection / XSS and is faster since it does not parse markup.
  • Switched innerText to textContent: textContent is deterministic and faster since it skips layout recalc.
  • Guarded JSON.parse on localStorage: corrupted or missing keys previously threw a fatal SyntaxError; now falls back safely.

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: #486

@vercel

vercel Bot commented Aug 4, 2026

Copy link
Copy Markdown

Someone is attempting to deploy a commit to the kaif ansari 's projects Team on Vercel.

A member of the Team first needs to authorize it.

@netlify

netlify Bot commented Aug 4, 2026

Copy link
Copy Markdown

Deploy Preview for gamehub-99999 failed.

Name Link
🔨 Latest commit f3f2b5c
🔍 Latest deploy log https://app.netlify.com/projects/gamehub-99999/deploys/6a718f2dd2bd7200088fc6c4

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