This commit is contained in:
Denis Angell
2023-01-24 16:29:55 -05:00
parent 139d57921a
commit 8a8c980be7
3 changed files with 39 additions and 39 deletions

View File

@@ -771,7 +771,7 @@ trustTransferLockedBalance(
S& sleDstAcc,
STAmount const& amount, // issuer, currency are in this field
int deltaLockCount, // -1 decrement, +1 increment, 0 unchanged
Rate const& xferRate, // TransferRate
Rate const& lXferRate, // locked transfer rate
beast::Journal const& j,
R dryRun)
{
@@ -923,11 +923,11 @@ trustTransferLockedBalance(
// default to amount
auto dstAmt = amount;
// if transfer rate
if (xferRate != parityRate)
if (lXferRate != parityRate)
{
// compute transfer fee, if any
auto const xferFee =
amount.value() - divideRound(amount, xferRate, amount.issue(), true);
amount.value() - divideRound(amount, lXferRate, amount.issue(), true);
// compute balance to transfer
dstAmt = amount.value() - xferFee;
}

View File

@@ -88,7 +88,7 @@ transResults()
MAKE_ERROR(tecINSUFFICIENT_FUNDS, "Not enough funds available to complete requested transaction."),
MAKE_ERROR(tecOBJECT_NOT_FOUND, "A requested object could not be located."),
MAKE_ERROR(tecINSUFFICIENT_PAYMENT, "The payment is not sufficient."),
MAKE_ERROR(tecPRECISION_LOSS, "The IOU amounts used by the transaction cannot interact."),
MAKE_ERROR(tecPRECISION_LOSS, "The amounts used by the transaction cannot interact."),
MAKE_ERROR(tefALREADY, "The exact transaction was already in this ledger."),
MAKE_ERROR(tefBAD_ADD_AUTH, "Not authorized to add account."),
MAKE_ERROR(tefBAD_AUTH, "Transaction's public key is not authorized."),