Closed leirbag95 closed 2 years ago
Can you provide the list of wallets this was tested on ?
3 kinds of wallet: 2V4DBUdN6DksieeJoVrYaCyjcCreBgmN6tW4fFP4mg3z with 0.10 splToken 4NQCytpkZSPDPw5jN57ceMzc65dwfMALxA8xud5f9tFz with empty balance GhD9sSJSxjGy4ftZtSs9ZPohYkccmTq8nzvwwzLRx3C4 with empty balance too
The method used to sign a message from a provider (
provider_sign(provider, message)
) was the following:This method does not work when a user wants to sign directly from a wallet, especially with phantom. So I checked that the provider is an
instanceOf
of a known structure and provide a class abstraction for every method I want to use (cleaner approach, but more boilerplate).I was inspired by the TS SDK: https://github.com/aleph-im/aleph-sdk-ts/blob/main/src/providers/JsonRPCWallet.ts