Merge pull request #32 from rqbazan/fix-shift-jis-mime-name

fix: change Shift-JIS MIME to Shift_JIS
This commit is contained in:
Dmitry Shirokov 2020-07-06 15:08:20 +10:00 committed by GitHub
commit 6de3bc47d3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 5 additions and 5 deletions

View File

@ -61,7 +61,7 @@ chardet
- ISO-2022-JP
- ISO-2022-KR
- ISO-2022-CN
- Shift-JIS
- Shift_JIS
- Big5
- EUC-JP
- EUC-KR

View File

@ -3,8 +3,8 @@ import * as chardet from '..';
describe('Multibyte Character Sets', () => {
var base = __dirname + '/../test/data/encodings';
it('should return SHIFT-JIS', () => {
expect(chardet.detectFileSync(base + '/shiftjis')).toBe('Shift-JIS');
it('should return Shift_JIS', () => {
expect(chardet.detectFileSync(base + '/shiftjis')).toBe('Shift_JIS');
});
it('should return GB18030', () => {

View File

@ -201,11 +201,11 @@ class mbcs implements Recogniser {
}
/**
* Shift-JIS charset recognizer.
* Shift_JIS charset recognizer.
*/
export class sjis extends mbcs {
name() {
return 'Shift-JIS';
return 'Shift_JIS';
}
language() {
return 'ja';