You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[SDK] Fix: Only request specified wallet connect chains (#4832)
Falls in line with the WC spec and appeases some picky wallets
<!-- start pr-codex -->
---
## PR-Codex overview
This PR focuses on fixing wallet connection issues in the `thirdweb` package, particularly for wallets with limited chain support. It improves handling of optional chains and modifies how chains are requested.
### Detailed summary
- Updated handling of `optionalChains` to default to `[1]` if empty.
- Changed `chains` to be `undefined` if `chainToRequest` is not provided.
- Modified `setRequestedChainsIds` function to accept `chains` as `undefined`.
- Simplified logic for `chainsToRequest` to use `undefined` when no chains are available.
> ✨ Ask PR-Codex anything about this PR by commenting with `/codex {your question}`
<!-- end pr-codex -->
0 commit comments