Calldesc fix

This commit is contained in:
DanB
2017-05-22 10:14:27 +02:00
parent b0d4d8c42a
commit 81464d2364
2 changed files with 6 additions and 3 deletions

View File

@@ -713,7 +713,9 @@ func (cd *CallDescriptor) Debit() (cc *CallCost, err error) {
}
_, err = guardian.Guardian.Guard(func() (iface interface{}, err error) {
cc, err = cd.debit(account, cd.DryRun, !cd.DenyNegativeAccount)
cc.AccountSummary = cd.AccountSummary()
if err == nil {
cc.AccountSummary = cd.AccountSummary()
}
return
}, 0, lkIDs...)
return
@@ -779,7 +781,9 @@ func (cd *CallDescriptor) MaxDebit() (cc *CallCost, err error) {
}
//log.Print("Remaining duration: ", remainingDuration)
cc, err = cd.debit(account, cd.DryRun, !cd.DenyNegativeAccount)
cc.AccountSummary = cd.AccountSummary()
if err == nil {
cc.AccountSummary = cd.AccountSummary()
}
//log.Print(balanceMap[0].Value, balanceMap[1].Value)
return
}, 0, lkIDs...)

View File

@@ -384,7 +384,6 @@ func (rs *RedisStorage) GetRatingPlan(key string, skipCache bool, transactionID
return nil, err
}
cache.Set(key, rp, cacheCommit(transactionID), transactionID)
fmt.Printf("RatingPlan: %s\n", utils.ToJSON(rp))
return
}