-
Notifications
You must be signed in to change notification settings - Fork 168
Include limbo balance in Home screen balance. #1009
Conversation
src/action/wallet.js
Outdated
| log.error('Getting limbo balance failed', err); | ||
| } | ||
| } | ||
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
store.limboBalanceSatoshis should be done in getPendingChannels of channel actions as that grpc api is already being polled. Doing it here would result in the api being polled twice.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed
| pendingBalanceSatoshis + | ||
| channelBalanceSatoshis + | ||
| limboBalanceSatoshis | ||
| ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Although store.limboBalanceSatoshis is set in channel actions I would also compute this here 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, I'm confused what this means. What is being computed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just saying it makes sense to use the ComputedWallet module here. So no changes needed :)
| expect(store.totalBalanceSatoshis, 'to equal', 100010001); | ||
| expect(store.totalBalanceLabel, 'to match', /1[,.]000[,.]100[,.]01/); | ||
| expect(store.totalBalanceSatoshis, 'to equal', 100010101); | ||
| expect(store.totalBalanceLabel, 'to match', /1[,.]000[,.]101[,.]01/); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice test 👍
| pendingBalanceSatoshis + | ||
| channelBalanceSatoshis + | ||
| limboBalanceSatoshis | ||
| ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just saying it makes sense to use the ComputedWallet module here. So no changes needed :)
Closes #1006.