From 15388338e7c80ad4d84888e14e8af6b843f49f21 Mon Sep 17 00:00:00 2001 From: pate Date: Thu, 25 Apr 2002 15:51:33 +0000 Subject: [PATCH] fixed an unitialized variable error in &mktablerow --- C4/Output.pm | 23 +++++++++++------------ 1 file changed, 11 insertions(+), 12 deletions(-) diff --git a/C4/Output.pm b/C4/Output.pm index 3783eb28a9..fb8a5f030f 100644 --- a/C4/Output.pm +++ b/C4/Output.pm @@ -146,18 +146,17 @@ sub mktablerow { my $i=0; my $string=""; while ($i <$cols){ - if ($data[$cols] ne ''){ - #check for backgroundimage - $string.=""; - } else { - $string.=""; - } - if ($data[$i] eq "") { - $string.="   "; - } else { - $string.="$data[$i]"; - } - $i++; + if (defined $data[$cols]) { # if there is a background image + $string.=""; + } else { # if there's no background image + $string.=""; + } + if ($data[$i] eq "") { + $string.="   "; + } else { + $string.="$data[$i]"; + } + $i++; } $string=$string."\n"; return($string); -- 2.39.5