Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion lib/utils/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ var utils = module.exports = {
},
xmlEncode: function(text) {
// eslint-disable-next-line no-control-regex
return text.replace(/[<>&'"\x7F\x00-\x08\x0A-\x0C\x0E-\x1F]/g, function(c) {
return text.replace(/[<>&'"\x7F\x00-\x08\x0B-\x0C\x0E-\x1F]/g, function(c) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you also add a unit test for this (in spec/unit/utils/utils.spec.js to ensure \x0a is retained

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Weird that the previous PR that was supposed to fix this same issue wasn't required to have a unit test.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had a lot more spare time then. Thanks for doing this - I'll publish tonight.

switch (c) {
case '<': return '&lt;';
case '>': return '&gt;';
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "exceljs",
"version": "0.4.12",
"version": "0.4.13",
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bumping the package version is managed by the release scripts (npm version patch, etc). Please can you revert this line

"description": "Excel Workbook Manager - Read and Write xlsx and csv Files.",
"private": false,
"license": "MIT",
Expand Down