When importing accounts using private key, phantom is throwing -32603 when trying to connect not imported ones. #302
Unanswered
mojtabast
asked this question in
Help & Support
Replies: 1 comment
-
Hey @mojtabast, Thanks for writing in! We are aware of a bug where the ethereum provider is injected when it shouldn't be. I don't have an eta on the fix. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Summary
If user enabled multi chains for its wallet (Solana, Ethereum, Polygon), Phantom is injecting
solana
andethereum
intowindow
. But if a user added an account which is only one of these (for example, only Ethereum) usingImport Private Key
option, As an dApp developer, we can not detect available networks since both of.solana
and.ethereum
are injected.In this scenario, I think phantom should do one of these:
Active Networks
which means if a network is not available, instance shouldn't be injected intowindow
.-32603
to let developers detect this case and handle it accordingly.Example
No response
Steps to Reproduce
Import Private Key
option.window.phantom.solana.connect()
. it throw an -32603.Phantom Version
No response
Is there an existing discussion for this?
Beta Was this translation helpful? Give feedback.
All reactions