export existing contribution predictor
This commit is contained in:
@@ -44,10 +44,10 @@ func NewInterestPredictor(namePattern string, currencyPattern string, apy float6
|
||||
|
||||
func NewAutoContributionPredictor(reg ledger.Register) Predictor {
|
||||
monthlyRate := getMonthlyAutoContributionRates(reg)
|
||||
return newAutoContributionPredictor(monthlyRate)
|
||||
return NewContributionPredictor(monthlyRate)
|
||||
}
|
||||
|
||||
func newAutoContributionPredictor(monthlyRate map[string]ledger.Balance) Predictor {
|
||||
func NewContributionPredictor(monthlyRate ledger.Balances) Predictor {
|
||||
return func(given ledger.Balances, delta time.Duration) ledger.Balances {
|
||||
months := float64(delta) / float64(month)
|
||||
result := make(ledger.Balances)
|
||||
|
||||
Reference in New Issue
Block a user