From d3e5555b5c0b4cef6d5a2cdbb95beb464b97ea65 Mon Sep 17 00:00:00 2001 From: Radu Ioan Fericean Date: Mon, 21 Apr 2014 12:03:15 +0300 Subject: [PATCH] fix for rating subject shortucts --- engine/balances.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/engine/balances.go b/engine/balances.go index 2f285c633..4a1fd7f50 100644 --- a/engine/balances.go +++ b/engine/balances.go @@ -176,15 +176,15 @@ func (b *Balance) DebitMinutes(cc *CallCost, count bool, ub *Account, moneyBalan // if increment it's not at the begining we must split the timespan newTs = ts.SplitByIncrement(incrementIndex) } - newTs.RoundToDuration(time.Minute) + newTs.RoundToDuration(duration) newTs.RateInterval = &RateInterval{ Rating: &RIRate{ Rates: RateGroups{ &Rate{ GroupIntervalStart: 0, Value: 0, - RateIncrement: time.Minute, - RateUnit: time.Minute, + RateIncrement: duration, + RateUnit: duration, }, }, },