Skip to content

fix BOM header 0xFEFF problem for ucs2 encoding file #146

merged 1 commit into from Dec 29, 2013

2 participants

kiinoo commented Dec 26, 2013

···if (this.lines === 0 && this.options.encoding === 'utf8' && 0xFEFF === chars.charCodeAt(0)) ···
changed to
···if (this.lines === 0 && 0xFEFF === chars.charCodeAt(0)) ···

The reason is that not only 'utf8' has BOM headers, but also some other encodings, such as 'ucs2'.
so I suggest remove the BOMM header directly.

@wdavidw wdavidw merged commit 15aa4ce into wdavidw:master Dec 29, 2013

1 check passed

Details default The Travis CI build passed
wdavidw commented Dec 29, 2013


@wdavidw wdavidw added a commit that referenced this pull request Dec 29, 2013
@wdavidw Apply issue #146 to coffee code 31fee05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.