Skip to content

Commit

Permalink
connect
Browse files Browse the repository at this point in the history
  • Loading branch information
estebanmino committed May 6, 2024
1 parent 586aa46 commit ea27fd8
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion src/handleProviderRequest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -349,7 +349,14 @@ export const handleProviderRequest = ({
const supportedChainId = isSupportedChain?.(
Number(proposedChain.chainId),
);
if (!supportedChainId || !activeSession) {
if (!activeSession) {
(await messengerProviderRequest({
method: 'eth_requestAccounts',
id,
params,
meta,
})) as { address: Address; chainId: number };
} else if (!supportedChainId) {
onSwitchEthereumChainNotSupported?.({
proposedChain,
callbackOptions: meta,
Expand Down

0 comments on commit ea27fd8

Please sign in to comment.