The code says
if($business_isbn_loaded) {
my $isbn_object = Business::ISBN->new($isbn);
croak("Invalid ISBN specified.\n") if (!$isbn_object-
Show quoted text
>is_valid);
}
but this doesn't take account of the case when Business::ISBN->new
returns "undefined", which may happen (from documentation):
"If the constructor decides it cannot create an object, it returns
undef."
It's necessary to change the above to
if (!$isbn_object || !$isbn_object->is_valid)
I hope this bug report is helpful.