diff --git a/packages/injected/src/helpers.ts b/packages/injected/src/helpers.ts index 8622b3ea2..8928f3cb2 100644 --- a/packages/injected/src/helpers.ts +++ b/packages/injected/src/helpers.ts @@ -40,7 +40,7 @@ export const isWalletAvailable = ( // For multiple injected providers, check providers array // example coinbase inj wallet pushes over-ridden wallets // into a providers array at window.ethereum - return !!provider.providers?.some(provider => + return Array.isArray(provider.providers) && !!provider.providers?.some(provider => checkProviderIdentity({ provider, device }) ) } diff --git a/packages/injected/src/wallets.ts b/packages/injected/src/wallets.ts index 77e7544dc..b7a5d31ab 100644 --- a/packages/injected/src/wallets.ts +++ b/packages/injected/src/wallets.ts @@ -581,7 +581,7 @@ const bitget: InjectedWalletModule = { label: ProviderLabel.Bitget, injectedNamespace: InjectedNameSpace.Bitget, checkProviderIdentity: ({ provider }) => - !!provider && !!provider['ethereum'][ProviderIdentityFlag.Bitget], + !!provider && !!provider['ethereum'] && !!provider['ethereum'][ProviderIdentityFlag.Bitget], getIcon: async () => (await import('./icons/bitget.js')).default, getInterface: async () => ({ provider: window.bitkeep && window.bitkeep.ethereum