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

Handle LBC unavailable error from ShapeShift without breaking the app #1739

Merged
merged 1 commit into from Jul 9, 2018

Conversation

Projects
None yet
2 participants
@seanyesmunt
Copy link
Member

seanyesmunt commented Jul 8, 2018

If LBC is unavailable on shapeshift (like it is right now) the app breaks on the Get Credits page. We need to explicitly check that it is available before worrying about other coins availability.

If it's unavailable, stop and show an error message.

@seanyesmunt seanyesmunt force-pushed the shapeshift-fix branch from 6768925 to 7ab590d Jul 9, 2018

@seanyesmunt seanyesmunt changed the title wip Handle LBC unavailable error from ShapeShift without breaking the app Jul 9, 2018

@seanyesmunt seanyesmunt requested a review from kauffj Jul 9, 2018

@lbry-bot lbry-bot assigned kauffj and unassigned seanyesmunt Jul 9, 2018

@kauffj

kauffj approved these changes Jul 9, 2018

@@ -1,3 +1,5 @@
export const NO_DEPOSITS = 'no_deposits';
export const RECEIVED = 'received';
export const COMPLETE = 'complete';
export const AVAILABLE = 'available';
export const UNAVAILABLE = 'unavailable';

This comment has been minimized.

@kauffj

kauffj Jul 9, 2018

Member

👍 good stuff

@@ -65,9 +66,16 @@ export const shapeShiftInit = () => (dispatch: Dispatch): ThunkAction => {
return shapeShift
.coinsAsync()
.then(coinData => {
if (coinData.LBC.status === SHAPESHIFT_STATUSES.UNAVAILABLE) {
dispatch({

This comment has been minimized.

@kauffj

kauffj Jul 9, 2018

Member

return dispatch ?

@lbry-bot lbry-bot assigned seanyesmunt and unassigned kauffj and seanyesmunt Jul 9, 2018

@seanyesmunt seanyesmunt force-pushed the shapeshift-fix branch from 7ab590d to bf2bc68 Jul 9, 2018

@seanyesmunt seanyesmunt merged commit 5cd70d5 into master Jul 9, 2018

2 checks passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details

@seanyesmunt seanyesmunt deleted the shapeshift-fix branch Sep 10, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.