6290: Fix warning on XSLT.pm
authorMarcel de Rooy <m.de.rooy@rijksmuseum.nl>
Mon, 2 May 2011 07:49:49 +0000 (09:49 +0200)
committerChris Cormack <chrisc@catalyst.net.nz>
Thu, 11 Aug 2011 00:54:47 +0000 (12:54 +1200)
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
C4/XSLT.pm

index 28a70fc..4dafff3 100755 (executable)
@@ -222,7 +222,7 @@ sub buildKohaItemsNamespace {
         } else {
             $status = "available";
         }
-        my $homebranch = xml_escape($branches->{$item->{homebranch}}->{'branchname'});
+        my $homebranch = $item->{homebranch}? xml_escape($branches->{$item->{homebranch}}->{'branchname'}):'';
            my $itemcallnumber = xml_escape($item->{itemcallnumber});
         $xml.= "<item><homebranch>$homebranch</homebranch>".
                "<status>$status</status>".