Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support eth_requestAccounts #3250

Closed
gpersoon opened this issue Nov 29, 2019 · 1 comment
Closed

Support eth_requestAccounts #3250

gpersoon opened this issue Nov 29, 2019 · 1 comment

Comments

@gpersoon
Copy link

Expected behavior

Begin able to use eth_requestAccounts in a native way.
Because metamask will deprecate ethereum.enable().
See: https://metamask.github.io/metamask-docs/API_Reference/Ethereum_Provider#new-api

Actual behavior

It possible to use eth_requestAccounts in the following way:

web3.extend({   
                methods: [{
                    name: 'eth_requestAccounts',
                    call: 'eth_requestAccounts',
                    params: 0
                }]
            }); 
await web3.eth_requestAccounts();

Steps to reproduce the behavior

Logs

Versions

Web3.js 1.2.4

@nivida
Copy link
Contributor

nivida commented Nov 30, 2019

Thanks for opening this issue! The eth_requestAccounts JSON-RPC method got already implemented with PR #3219. We will release this addition as soon as possible.

Edit:
See CHANGELOG.md

@nivida nivida closed this as completed Nov 30, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants