X-Git-Url: https://git.camperquake.de/gitweb.cgi?a=blobdiff_plain;ds=sidebyside;f=videosite%2FYouTubeGrabber.pm;h=17f1d8d9cf0304c46c1d2d19136af09342fa01a3;hb=22f4cccc663915b14612a8419e4a36a5bbcca9b7;hp=b3fe738ccd776f002b6e179ab1ab4ba41eb1f46c;hpb=26eec5c0f1ecd39c8995b5f4d7d10d05df4913cd;p=videosite.git diff --git a/videosite/YouTubeGrabber.pm b/videosite/YouTubeGrabber.pm index b3fe738..17f1d8d 100644 --- a/videosite/YouTubeGrabber.pm +++ b/videosite/YouTubeGrabber.pm @@ -120,7 +120,7 @@ sub _parse { SWF_ARGS: while ($tag = $p->get_tag('div', 'meta', 'script')) { if ('meta' eq $tag->[0]) { - if ('title' eq $tag->[1]->{'name'}) { + if (exists($tag->[1]->{'name'}) and ('title' eq $tag->[1]->{'name'})) { $metadata->{'TITLE'} = $tag->[1]->{'content'}; # Convert HTML entities in the title. This is a bit convoluted. $metadata->{'TITLE'} = encode("utf8",