Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue 296 #343

Merged
merged 3 commits into from
Jun 22, 2017
Merged

Issue 296 #343

merged 3 commits into from
Jun 22, 2017

Conversation

holly-weisser
Copy link
Contributor

Let new lines through xmlEncode function. See github issue 296 (#296).

package.json Outdated
@@ -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

@@ -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.

@guyonroche guyonroche merged commit b3cd02a into exceljs:master Jun 22, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants