Skip to content

Comments

fix: use Object.defineProperty for navigator polyfill#94

Open
dallen4 wants to merge 1 commit intomainfrom
fix-global-navigator
Open

fix: use Object.defineProperty for navigator polyfill#94
dallen4 wants to merge 1 commit intomainfrom
fix-global-navigator

Conversation

@dallen4
Copy link
Owner

@dallen4 dallen4 commented Feb 1, 2026

Summary

Fixes the global navigator polyfill in the CLI inject script to use Object.defineProperty on globalThis instead of direct assignment. This resolves issues in environments where navigator is a read-only property.

Resolves #93

Changes

  • Replace direct global.navigator assignment with Object.defineProperty on globalThis (d316f28)
  • Set writable and configurable to true for compatibility
  • Use globalThis instead of global for the navigator reference

Testing Checklist

  • Verify CLI peer connection initialization works correctly
  • Test in environments where navigator was previously read-only

Replace direct global.navigator assignment with Object.defineProperty
on globalThis to handle environments where navigator is read-only.
@vercel
Copy link

vercel bot commented Feb 1, 2026

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

Project Deployment Actions Updated (UTC)
deadrop Ready Ready Preview, Comment Feb 1, 2026 7:57pm

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.

CLI: Fix global.navigator assignment for Node.js v22+

1 participant