Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

make Author data retrieval more robust

  • Loading branch information...
commit e549f65e6d52de6b56f9020bc5e60f3ec6eb40a3 1 parent 7c70aeb
@moritz authored
Showing with 2 additions and 2 deletions.
  1. +2 −2 lib/WebService/Libris/Author.pm
View
4 lib/WebService/Libris/Author.pm
@@ -11,7 +11,7 @@ sub fragments {
sub _description {
my $self = shift;
my $url = join '/', $self->fragments;
- $self->dom->at(qq{description[about\$="$url"]})
+ $self->dom->at(qq{description[about\$="$url"]}) // Mojo::DOM->new;
}
sub birthyear {
@@ -37,4 +37,4 @@ sub names {
map $_->text, shift->_description->find('name')->each;
}
-1;
+1;
Please sign in to comment.
Something went wrong with that request. Please try again.