# length($cdr->billsec) ? $cdr->billsec : $cdr->duration;
my $seconds = $use_duration ? $cdr->duration : $cdr->billsec;
$seconds += $granularity - ( $seconds % $granularity )
if $seconds # don't granular-ize 0 billsec calls (bills them)
# length($cdr->billsec) ? $cdr->billsec : $cdr->duration;
my $seconds = $use_duration ? $cdr->duration : $cdr->billsec;
$seconds += $granularity - ( $seconds % $granularity )
if $seconds # don't granular-ize 0 billsec calls (bills them)