refactor: Restructure LendingHelpers to improve readability (#7807)

This commit is contained in:
Vito Tumas
2026-07-16 17:47:56 +02:00
committed by Gregory Tsipenyuk
parent 66be91d5b3
commit 295f53c400
3 changed files with 392 additions and 403 deletions

View File

@@ -263,10 +263,11 @@ constructLoanState(
Number const& principalOutstanding,
Number const& managementFeeOutstanding);
// Constructs a valid LoanState object from a Loan object, which always has
// rounded values
// Overload of constructLoanState() that reads the three tracked fields
// directly from a Loan ledger object, which always holds rounded values,
// rather than taking them as separate Number arguments.
LoanState
constructRoundedLoanState(SLE::const_ref loan);
constructLoanState(SLE::const_ref loan);
Number
computeManagementFee(