Skip to content

Commit f680496

Browse files
fix: Coinbase Wallet connection on same chain (#5656)
1 parent df734ba commit f680496

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed

.changeset/dirty-goats-invent.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"thirdweb": patch
3+
---
4+
5+
Fix connecting to cb wallet browser extension when already on the same chain

packages/thirdweb/src/wallets/coinbase/coinbase-web.ts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -463,11 +463,7 @@ export async function connectCoinbaseWalletSDK(
463463
? options.chain
464464
: getCachedChain(chainId);
465465
// Switch to chain if provided
466-
if (
467-
connectedChainId &&
468-
options?.chain &&
469-
connectedChainId !== options?.chain.id
470-
) {
466+
if (chainId && options?.chain && chainId !== options?.chain.id) {
471467
await switchChainCoinbaseWalletSDK(provider, options.chain);
472468
chain = options.chain;
473469
}

0 commit comments

Comments
 (0)