labscommunity / arweave-wallet-kit

A React library for interaction with different Arweave wallets
https://docs.arweavekit.com/wallets/wallet-kit
MIT License
16 stars 9 forks source link

fix: Add error handling to ans profile fetch #6

Closed pawanpaudel93 closed 1 year ago

pawanpaudel93 commented 1 year ago

Bug

Getting this error on development mode in Next.js when a wallet is connected and the wallet kit tries to fetch the ANS profile. ANS API might not be working and this is throwing the error below.

image

Fix

Added try catch to ANS profile fetch

pawanpaudel93 commented 1 year ago

@martonlederer Also, I have created a demo app here with wallet kit setup which you could clone and check the error: https://github.com/pawanpaudel93/wallet-kit-ans