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

feat: handle undefined price values #313

Merged
merged 1 commit into from
May 31, 2022

Conversation

peterslany
Copy link
Contributor

This PR adds handling of the prices in cases when CoinGecko API does not return requested data. Majority of changes are just additions of optional chaining operator ?..

Visual preview
When price data is unavailable, dash is shown (bottom-right corner)
image

@vercel
Copy link

vercel bot commented May 30, 2022

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated
interbtc-ui-interlay ✅ Ready (Inspect) Visit Preview May 30, 2022 at 11:59AM (UTC)
interbtc-ui-kintsugi ✅ Ready (Inspect) Visit Preview May 30, 2022 at 11:59AM (UTC)
interbtc-ui-testnet ✅ Ready (Inspect) Visit Preview May 30, 2022 at 11:59AM (UTC)

Copy link
Contributor

@crypto-engineer crypto-engineer left a comment

Choose a reason for hiding this comment

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

LGTM
I approve this PR since I'll leave the decision on my comment to you. :)

src/common/utils/utils.ts Show resolved Hide resolved
@peterslany peterslany merged commit f1251b4 into master May 31, 2022
@peterslany peterslany deleted the peter/feat-handle-coingecko-undefined-response branch May 31, 2022 14:05
@peterslany peterslany restored the peter/feat-handle-coingecko-undefined-response branch May 31, 2022 14:06
@crypto-engineer crypto-engineer deleted the peter/feat-handle-coingecko-undefined-response branch June 1, 2022 07:47
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.

None yet

2 participants