summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorivan <ivan>2011-05-01 20:02:39 +0000
committerivan <ivan>2011-05-01 20:02:39 +0000
commita8d6ee9aa912326566abaaf6e0ebac960a4b7217 (patch)
tree4fff3322a76bb95a962a65fb356e4932c613398e
parenta4436d6dcd4d0d0a7e2f6500d4dd668296ad5f19 (diff)
cdr reimporting, RT#12181
-rw-r--r--bin/cdr.reimport6
1 files changed, 4 insertions, 2 deletions
diff --git a/bin/cdr.reimport b/bin/cdr.reimport
index 1b2f198d6..51c62d2ea 100644
--- a/bin/cdr.reimport
+++ b/bin/cdr.reimport
@@ -34,7 +34,7 @@ my $cb = sub {
$new++;
return;
}
- die "too many matches found!" if scalar(@exists) > 1;
+ return "too many matches found!" if scalar(@exists) > 1;
my $exists = $exists[0];
if ( $exists->freesidestatus ) {
@@ -43,9 +43,11 @@ my $cb = sub {
} else {
$rep++;
my $error = $exists->delete;
- die $error if $error;
+ return $error if $error;
}
+ return '';
+
};
my $error = FS::cdr::batch_import( {