Skip to content

Commit 1e87945

Browse files
Bump @types/node from 13.13.5 to 14.0.23 (#67)
* Bump @types/node from 13.13.5 to 14.0.23 Bumps [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) from 13.13.5 to 14.0.23. - [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases) - [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node) Signed-off-by: dependabot-preview[bot] <[email protected]> * fix encoding type Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com> Co-authored-by: laputa <[email protected]>
1 parent a0dfb3b commit 1e87945

File tree

3 files changed

+7
-5
lines changed

3 files changed

+7
-5
lines changed

lib/cue.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,10 +43,12 @@ export function parse(filename: string): ICueSheet {
4343
}
4444

4545
cuesheet.encoding = chardet.detect(fs.readFileSync(filename));
46-
let encoding = cuesheet.encoding;
46+
let encoding: BufferEncoding = 'utf8';
4747

4848
if (cuesheet.encoding.startsWith('ISO-8859-')) {
4949
encoding = 'binary';
50+
} else if (cuesheet.encoding.toUpperCase() === 'UTF-16 LE') {
51+
encoding = 'utf16le';
5052
}
5153

5254
const lines = (fs.readFileSync(filename, {encoding, flag: 'r'}) as any)

package-lock.json

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
"chardet": "^1.0.0"
4242
},
4343
"devDependencies": {
44-
"@types/node": "^13.7.1",
44+
"@types/node": "^14.0.23",
4545
"expect.js": "^0.3.1",
4646
"mocha": "^7.0.1",
4747
"tslint": "^6.0.0",

0 commit comments

Comments
 (0)