Fixed GetBudget

This commit is contained in:
Evan Duffield 2015-07-14 16:06:00 -07:00
parent a4e3031db1
commit 9e9e01b5f6
2 changed files with 2 additions and 1 deletions

View File

@ -593,7 +593,7 @@ std::vector<CBudgetProposal*> CBudgetManager::GetBudget()
CBudgetProposal* pbudgetProposal = &((*it2).second);
//prop start/end should be inside this period
if(pbudgetProposal->nBlockStart <= nBlockStart && pbudgetProposal->nBlockEnd >= nBlockEnd && pbudgetProposal->GetYeas()-pbudgetProposal->GetNays() > mnodeman.CountEnabled()/10)
if(pbudgetProposal->fValid && pbudgetProposal->nBlockStart <= nBlockStart && pbudgetProposal->nBlockEnd >= nBlockEnd && pbudgetProposal->GetYeas()-pbudgetProposal->GetNays() > mnodeman.CountEnabled()/10)
{
if(nTotalBudget == nBudgetAllocated){
pbudgetProposal->SetAllotted(0);

View File

@ -318,6 +318,7 @@ Value mnbudget(const Array& params, bool fHelp)
std::string strError = "";
bObj.push_back(Pair("IsValid", pbudgetProposal->IsValid(strError)));
bObj.push_back(Pair("fValid", (int64_t)pbudgetProposal->fValid));
resultObj.push_back(Pair(pbudgetProposal->GetName().c_str(), bObj));
}