Compare Numbers against beast::zero

This commit is contained in:
Ed Hennis
2025-10-16 16:04:16 -04:00
parent baabf142e4
commit 98d1cf07ed
2 changed files with 4 additions and 4 deletions

View File

@@ -452,14 +452,14 @@ LoanPay::doApply()
view, brokerPayee, asset, fhIGNORE_FREEZE, ahIGNORE_AUTH, j_);
#endif
if (totalPaidToVault != Number{})
if (totalPaidToVault != beast::zero)
{
if (auto const ter = requireAuth(
view, asset, vaultPseudoAccount, AuthType::StrongAuth))
return ter;
}
if (totalPaidToBroker != Number{})
if (totalPaidToBroker != beast::zero)
{
if (brokerPayee == account_)
{

View File

@@ -401,7 +401,7 @@ LoanSet::doApply()
// avoids dividing by 0.
auto const roundedPayment = roundPeriodicPayment(
vaultAsset, properties.periodicPayment, properties.loanScale);
if (roundedPayment == Number{})
if (roundedPayment == beast::zero)
{
JLOG(j_.warn()) << "Loan Periodic payment ("
<< properties.periodicPayment << ") rounds to 0. ";
@@ -494,7 +494,7 @@ LoanSet::doApply()
// 2. Transfer originationFee, if any, from vault pseudo-account to
// LoanBroker owner.
if (originationFee != Number{})
if (originationFee != beast::zero)
{
// Create the holding if it doesn't already exist (necessary for MPTs).
// The owner may have deleted their MPT / line at some point.