carp and not croak if MST or XRF file isn't found (calling program will
[Biblio-Isis] / lib / Biblio / Isis.pm
index 2690020..ea1c64f 100644 (file)
@@ -9,7 +9,7 @@ use Data::Dumper;
 BEGIN {
        use Exporter ();
        use vars qw ($VERSION @ISA @EXPORT @EXPORT_OK %EXPORT_TAGS);
-       $VERSION     = 0.11;
+       $VERSION     = 0.12;
        @ISA         = qw (Exporter);
        #Give a hoot don't pollute, do not export more than needed by default
        @EXPORT      = qw ();
@@ -147,7 +147,10 @@ sub new {
        push @must_exist, "fdt" if ($self->{read_fdt});
 
        foreach my $ext (@must_exist) {
-               croak "missing ",uc($ext)," file in ",$self->{isisdb} unless ($self->{$ext."_file"});
+               unless ($self->{$ext."_file"}) {
+                       carp "missing ",uc($ext)," file in ",$self->{isisdb};
+                       return;
+               }
        }
 
        print STDERR "## using files: ",join(" ",@isis_files),"\n" if ($self->{debug});