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

Add error handling to StakeKit utils #5406

Merged
merged 2 commits into from
Dec 18, 2024
Merged

Conversation

peachbits
Copy link
Contributor

@peachbits peachbits commented Dec 17, 2024

CHANGELOG

Does this branch warrant an entry to the CHANGELOG?

  • Yes
  • No

Dependencies

none

Requirements

If you have made any visual changes to the GUI. Make sure you have:

  • Tested on iOS device
  • Tested on Android device
  • Tested on small-screen device (iPod Touch)
  • Tested on large-screen device (tablet)

Copy link
Contributor

@swansontec swansontec left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yuck for having to work around this broken API, but I see how it works.

@@ -83,3 +87,10 @@ const checkInsufficientFunds = (res: unknown): void => {
throw new InsufficientFundsError({ tokenId: null })
}
}

const checkForError = (res: unknown): void => {
const error = asMaybe(asObject({ message: asString, type: asString, code: asNumber }))(res)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@peachbits peachbits force-pushed the matthew/coreum-missing-tx branch from 9db3841 to 58693bc Compare December 18, 2024 02:06
@peachbits peachbits merged commit 66c7061 into develop Dec 18, 2024
2 checks passed
@peachbits peachbits deleted the matthew/coreum-missing-tx branch December 18, 2024 02:27
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

Successfully merging this pull request may close these issues.

2 participants