From 4ba43998e1c6948070306f60e9bcc89c4028cbbd Mon Sep 17 00:00:00 2001 From: maxogden Date: Sun, 27 Mar 2011 15:16:39 -0700 Subject: [PATCH] properly escape double quotes --- lists/csv.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lists/csv.js b/lists/csv.js index 9fc9b66e..bee5b438 100644 --- a/lists/csv.js +++ b/lists/csv.js @@ -19,7 +19,7 @@ function(head, req) { if (row.value[headers[header]]) { if (startedOutput) send(","); var value = row.value[headers[header]]; - if (typeof(value) == "object") value = JSON.stringify(value).replace(/"/g, "\\\""); + if (typeof(value) == "object") value = JSON.stringify(value).replace(/\"/g, '""'); send("\"" + value + "\""); } else { if (startedOutput) send(",");