- die "Error running VoIP Innovations getDIDs: ".
- $search->{'statuscode'}. ': '. $search->{'status'}; #die??
+
+ my $error = "Error running VoIP Innovations getDIDs: ";
+ if ( $search->{'statuscode'} || $search->{'status'} ) {
+ $error .= $search->{'statuscode'}. ': '. $search->{'status'}. "\n";
+ } else {
+ $error .= Dumper($search);
+ }
+ warn $error;
+ die $error;