You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It tried to divide by zero when a token is new when calling this function:
function foreclosureTimePatron(address tokenPatron) public view returns (uint256) {
// patronage per second
uint256 pps = totalPatronOwnedTokenCost[tokenPatron].div(patronageDenominator).div(365 days);
return now.add(depositAbleToWithdraw(tokenPatron).div(pps)); // zero division if price is zero.
}
since totalPatronOwnedTokenCost[tokenPatron] can be zero, and you get a divide by zero issue
The text was updated successfully, but these errors were encountered:
It tried to divide by zero when a token is new when calling this function:
since
totalPatronOwnedTokenCost[tokenPatron]
can be zero, and you get a divide by zero issueThe text was updated successfully, but these errors were encountered: