Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -161,11 +161,19 @@
const {
wallet,
requestHandlers,
chains,
onConnect,
onDisconnect,
client: thirdwebClient,
} = options;
const chains = (() => {
if (options.chains && options.chains.length > 10) {
console.warn(
"WalletConnect: Can specify no more than 10 chains, truncating to the first 10 provided chains...",
);
return options.chains.slice(0, 10);
}

Check warning on line 174 in packages/thirdweb/src/wallets/wallet-connect/receiver/index.ts

View check run for this annotation

Codecov / codecov/patch

packages/thirdweb/src/wallets/wallet-connect/receiver/index.ts#L170-L174

Added lines #L170 - L174 were not covered by tests
return options.chains;
})();

if (walletConnectClientCache.has(thirdwebClient)) {
return walletConnectClientCache.get(thirdwebClient) as WalletConnectClient;
Expand Down
Loading