[Rt-devel] PATCH: silence warnings Elements/CollectionAsTable/Header

Jim Meyer purp at acm.org
Wed Nov 16 16:55:47 EST 2005


Attached.

--j
-- 
Jim Meyer, Geek at Large                                    purp at acm.org
-------------- next part --------------
--- share/html/Elements/CollectionAsTable/Header	2005-04-17 13:14:08.000000000 -0700
+++ local/html/Elements/CollectionAsTable/Header	2005-11-16 13:43:35.000000000 -0800
@@ -61,9 +61,9 @@
 
 my $item = 0;
 foreach my $col (@Format) {
     $item++;
-    if ( $col->{title} eq 'NEWLINE' ) {
+    if ( $col->{title} && ($col->{title} eq 'NEWLINE') ) {
         while ( $item < $maxitems ) {
             $m->out(qq{<th class="collection-as-table">&nbsp;</th>\n});
             $item++;
         }
@@ -72,9 +72,9 @@
         $m->out(qq{</tr>\n<tr class="collection-as-table">});
     }
     else {
         $m->out('<th class="collection-as-table">');
-        my $title = $col->{title};
+        my $title = $col->{title} || '';
         $title =~ s/^__(.*)__$/$1/o;
         $title = (
             $m->comp(
                 '/Elements/RT__Ticket/ColumnMap',


More information about the Rt-devel mailing list