From: ivan Date: Sun, 1 May 2011 20:02:38 +0000 (+0000) Subject: cdr reimporting, RT#12181 X-Git-Tag: freeside_2_3_0~311 X-Git-Url: http://git.freeside.biz/gitweb/?p=freeside.git;a=commitdiff_plain;h=790db5a543f9d697ed373acab2b95566634cf029 cdr reimporting, RT#12181 --- 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( {