]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Bug 179264 csv output for the buglist (see url inside) is invalid (too many "s)
authorbugreport%peshkin.net <>
Sun, 10 Nov 2002 14:40:05 +0000 (14:40 +0000)
committerbugreport%peshkin.net <>
Sun, 10 Nov 2002 14:40:05 +0000 (14:40 +0000)
r,a=justdave

globals.pl

index bee0ed9ff26133ff3ca4b1de3e9685934f684767..170ec8c41eb18e1bb11549d1450facfa9a5a4e63 100644 (file)
@@ -1586,15 +1586,12 @@ $::template ||= Template->new(
         # characters that need encoding.
         url_quote => \&Bugzilla::Util::url_quote,
         
-        # In CSV, quotes are doubled, and any value containing a quote or a
-        # comma is enclosed in quotes.
+        # In CSV, quotes are doubled, and we enclose the whole value in quotes
         csv => sub
         {
             my ($var) = @_;
-            $var =~ s/"/""/;
-            if ($var =~ /",/) {
-                $var = "\"$var\"";
-            }
+            $var =~ s/"/""/g;
+            $var = "\"$var\"";
             return $var;
         } ,
       } ,