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

Moralis.onAccountChanged is not a function #46

Open
socheat-leang opened this issue May 2, 2022 · 4 comments
Open

Moralis.onAccountChanged is not a function #46

socheat-leang opened this issue May 2, 2022 · 4 comments

Comments

@socheat-leang
Copy link

socheat-leang commented May 2, 2022

I have cloned the project and done the yarn command successfully in order to load node_modules

Anyway, When I run the project, I met the error below.
TypeError: Moralis.onAccountChanged is not a function. (In 'Moralis.onAccountChanged(function (address) { setWalletAddress(address[0]); })', 'Moralis.onAccountChanged' is undefined)

When I block this code, it can't make connect to wallet successfully.

The environment, I use the default from this boilerplate.

Do you have any suggestions or I miss some part? Please guide me in advance.

Thanks

@alexnguyennz
Copy link

Hi can you try changing that to Moralis.onAccountsChanged in the file at frontend/providers/MoralisDappProvider/MoralisDappProvider.js.

@ohmygaugh-crypto
Copy link

Hi can you try changing that to Moralis.onAccountsChanged in the file at frontend/providers/MoralisDappProvider/MoralisDappProvider.js.

Yup, I had the same issue and it was resolved with the suggestion above!

Silly typo

@snehal-delixus
Copy link

Hi have changed to Moralis.onAccountsChanged in the file at frontend/providers/MoralisDappProvider/MoralisDappProvider.js
but still i am getting error 404 on https://walletconnect.com/wallets and the popup with all the wallets is not shown

@alexnguyennz
Copy link

alexnguyennz commented Jul 28, 2022

@snehal-delixus Hi can you post on the Moralis forum in this thread: https://forum.moralis.io/t/ethereum-react-native-boilerplate-questions/4511

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

4 participants