handle domestic_prefix of 0, RT#11390
authorivan <ivan>
Sat, 12 Feb 2011 00:21:58 +0000 (00:21 +0000)
committerivan <ivan>
Sat, 12 Feb 2011 00:21:58 +0000 (00:21 +0000)
FS/FS/part_pkg/voip_cdr.pm

index 800f929..942ac6a 100644 (file)
@@ -475,7 +475,7 @@ sub calc_usage {
             }
 
           } else {
-            $countrycode = $domestic_prefix || '1';
+            $countrycode = length($domestic_prefix) ? $domestic_prefix : '1';
             $number =~ s/^$countrycode//;# if length($number) > 10;
           }