Skip to content

Commit

Permalink
[GUI] Fix wrongly displayed balance on Overview tab
Browse files Browse the repository at this point in the history
  • Loading branch information
Mrs-X committed May 6, 2018
1 parent 766d519 commit 6030877
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/qt/overviewpage.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -209,10 +209,11 @@ void OverviewPage::setBalance(const CAmount& balance, const CAmount& unconfirmed
nWatchOnlyLockedBalance = pwalletMain->GetLockedWatchOnlyBalance();
}
// PIV Balance
CAmount nTotalBalance = balance + unconfirmedBalance;
CAmount pivAvailableBalance = balance - immatureBalance - nLockedBalance;
CAmount nTotalBalance = balance + unconfirmedBalance + nLockedBalance;
CAmount pivAvailableBalance = balance - immatureBalance;
CAmount nTotalWatchBalance = watchOnlyBalance + watchUnconfBalance + watchImmatureBalance;
CAmount nUnlockedBalance = nTotalBalance - nLockedBalance;
CAmount nUnlockedBalance = nTotalBalance - nLockedBalance - nLockedBalance; // increment nLockedBalance twice because it was added to
// nTotalBalance above
// zPIV Balance
CAmount matureZerocoinBalance = zerocoinBalance - unconfirmedZerocoinBalance - immatureZerocoinBalance;
// Percentages
Expand Down

0 comments on commit 6030877

Please sign in to comment.