Bug 22294: Check return of as_isbn10 before calling methods on it
Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
This commit is contained in:
parent
d66432cafd
commit
b604e9c4fc
|
|
@ -898,7 +898,7 @@ sub _check_for_existing_bib {
|
|||
$isbn =~ s/\-//xmsg;
|
||||
if ( $isbn =~ m/(\d{13})/xms ) {
|
||||
my $b_isbn = Business::ISBN->new($1);
|
||||
if ( $b_isbn && $b_isbn->is_valid ) {
|
||||
if ( $b_isbn && $b_isbn->is_valid && $b_isbn->as_isbn10 ) {
|
||||
$search_isbn = $b_isbn->as_isbn10->as_string( [] );
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue