diff options
author | Jackson Tian <shyvo1987@gmail.com> | 2016-11-17 00:18:17 +0800 |
---|---|---|
committer | James M Snell <jasnell@gmail.com> | 2016-12-05 14:43:09 -0800 |
commit | fc3105511793863ef3ab15ed779f89249bf20204 (patch) | |
tree | 9fd58c3b4794dd5ee686a17154e4ef3d66c833f6 | |
parent | 02a4c081e93e527c1cff163534364a8d488c3777 (diff) | |
download | android-node-v8-fc3105511793863ef3ab15ed779f89249bf20204.tar.gz android-node-v8-fc3105511793863ef3ab15ed779f89249bf20204.tar.bz2 android-node-v8-fc3105511793863ef3ab15ed779f89249bf20204.zip |
internal/util: move the case 'latin1'
make the `case 'latin1':` near by `case 'binary':`.
PR-URL: https://github.com/nodejs/node/pull/9646
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Roman Reiss <me@silverwind.io>
Reviewed-By: Michaƫl Zasso <targos@protonmail.com>
-rw-r--r-- | lib/internal/util.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/internal/util.js b/lib/internal/util.js index ae8b1e0b64..238eb65891 100644 --- a/lib/internal/util.js +++ b/lib/internal/util.js @@ -112,15 +112,15 @@ exports.normalizeEncoding = function normalizeEncoding(enc) { case 'utf-8': return 'utf8'; case 'ucs2': - case 'utf16le': case 'ucs-2': + case 'utf16le': case 'utf-16le': return 'utf16le'; + case 'latin1': case 'binary': return 'latin1'; case 'base64': case 'ascii': - case 'latin1': case 'hex': return enc; default: |