]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Fix for bug 87596: improper definition of $::components in globals.pl
authorjustdave%syndicomm.com <>
Sun, 1 Jul 2001 09:00:56 +0000 (09:00 +0000)
committerjustdave%syndicomm.com <>
Sun, 1 Jul 2001 09:00:56 +0000 (09:00 +0000)
Patch by Dave Miller <justdave@syndicomm.com>
r= jake@acutex.net

enter_bug.cgi
globals.pl

index c1f4e61b15518bb958ccb37c73e4334bce919a1a..91622590c34275366ad41bd7cf1aaa1ae1fed843 100755 (executable)
@@ -237,7 +237,7 @@ my $platform_popup = make_popup('rep_platform', \@::legal_platform,
                                 pickplatform(), 0);
 my $opsys_popup = make_popup('op_sys', \@::legal_opsys, pickos(), 0);
 
-if (0 == $::components{$product}) {
+if (0 == @{$::components{$product}}) {
        print "<H1>Permission Denied</H1>\n";
        print "Sorry.  You need to have at least one component for this product\n";
        print "in order to create a new bug.  Go to the \"Components\" link to create\n";
index 2b3456959f7bb86832b8565dbc813962a54e7253..aa50355a05d0ff98425c771b28650b032a7cc4db 100644 (file)
@@ -501,7 +501,7 @@ sub GenerateVersionTable {
 
     foreach my $i (@list) {
         if (!defined $::components{$i}) {
-            $::components{$i} = "";
+            $::components{$i} = [];
         }
     }
     @::legal_versions = sort {uc($a) cmp uc($b)} keys(%varray);