- Manually add an XML header to the metadata
authorRalf Ertzinger <sun@ryoko.camperquake.de>
Fri, 29 Feb 2008 11:29:41 +0000 (12:29 +0100)
committerRalf Ertzinger <sun@ryoko.camperquake.de>
Fri, 29 Feb 2008 11:29:41 +0000 (12:29 +0100)
videosite/VimeoGrabber.pm

index 3e8ce6a..d09f4b2 100644 (file)
@@ -57,6 +57,9 @@ sub _parse {
         return undef;
     }
 
+    # There is no XML header in the data, which makes XML::Simple unhappy
+    $content = '<?xml version="1.0" encoding="UTF-8"?>' . $content;
+
     unless(defined($t = $p->XMLin($content, KeepRoot => 1))) {
         $self->error('Could not parse XML metadata');
         return undef;