Add comments where errors are not handled explicity

This commit is contained in:
TeoV
2021-01-19 09:40:45 +02:00
committed by Dan Christian Bogos
parent 34d17d0307
commit 2700d58c0f

View File

@@ -183,6 +183,8 @@ func (rS *RateS) rateProfileCostForEvent(rtPfl *engine.RateProfile, args *utils.
if rpCost.RateSIntervals, err = computeRateSIntervals(ordRts, 0, usage); err != nil {
return nil, err
}
// in case we have error it is returned in the function from above
// this came to light in coverage tests
rpCost.Cost, _ = engine.CostForIntervals(rpCost.RateSIntervals).Float64()
return