-
Notifications
You must be signed in to change notification settings - Fork 50
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
fix(wallet-mobile): NetworkError instance #3213
Conversation
maybe it's worth to still use the common package error but catching it by instance and use the UI error messages? |
Well, sure, we can use the one in common everywhere instead. None of the uses I see use the message from the error itself. |
apps/wallet-mobile/src/features/SetupWallet/useCases/CreateWallet/WalletDetailsScreen.tsx
Outdated
Show resolved
Hide resolved
…let/WalletDetailsScreen.tsx Signed-off-by: Juliano Lazzarotto <[email protected]>
The network error inside wallet is legacy, there are 2 fetchers, the legacy fetch, and the fetchData, which is the new one. There will be few places to replace. Please update them all to use -> from types Api.Error.Network, from types, the errors inside common can be dropped. |
related: https://emurgo.atlassian.net/browse/YOMO-1356
This one was confusing. Not sure why we have
NetworkError
exported from@yoroi/common
, but it's not the same one the wallet is throwing, so don't mix them up because theninstanceof
will fail.