diff --git a/papaparse.js b/papaparse.js index 2b59e84..2e23552 100755 --- a/papaparse.js +++ b/papaparse.js @@ -1008,7 +1008,7 @@ */ this.parse = function(input, baseIndex, ignoreLastRow) { - var quoteChar = _config.quoteChar || '"'; + var quoteChar = _config.quoteChar || '"'; if (!_config.newline) _config.newline = guessLineEndings(input, quoteChar); @@ -1258,7 +1258,7 @@ input = input.substr(0, 1024 * 1024); // max length 1 MB // Replace all the text inside quotes var re = new RegExp(quoteChar + '(.*?)' + quoteChar, 'gm'); - input = input.replace(re, '') + input = input.replace(re, ''); var r = input.split('\r'); diff --git a/tests/test-cases.js b/tests/test-cases.js index 231c986..27e521d 100644 --- a/tests/test-cases.js +++ b/tests/test-cases.js @@ -1214,7 +1214,7 @@ var PARSE_TESTS = [ input: '"a\r\na","b"\n"c","d"\n"e","f"\n"g","h"\n"i","j"\n', config: {}, expected: { - data: [['a\r\na', 'b'], ['c', 'd'], ['e', 'f'], ['g', 'h']['i', 'j']], + data: [['a\r\na', 'b'], ['c', 'd'], ['e', 'f'], ['g', 'h'], ['i', 'j']], errors: [] } }