summaryrefslogtreecommitdiff
path: root/lib/internal/encoding.js
diff options
context:
space:
mode:
Diffstat (limited to 'lib/internal/encoding.js')
-rw-r--r--lib/internal/encoding.js8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/internal/encoding.js b/lib/internal/encoding.js
index 09242be8dc..763ee42426 100644
--- a/lib/internal/encoding.js
+++ b/lib/internal/encoding.js
@@ -345,7 +345,7 @@ function makeTextDecoderICU() {
constructor(encoding = 'utf-8', options = {}) {
encoding = `${encoding}`;
if (typeof options !== 'object')
- throw new errors.Error('ERR_INVALID_ARG_TYPE', 'options', 'object');
+ throw new errors.Error('ERR_INVALID_ARG_TYPE', 'options', 'Object');
const enc = getEncodingFromLabel(encoding);
if (enc === undefined)
@@ -378,7 +378,7 @@ function makeTextDecoderICU() {
['ArrayBuffer', 'ArrayBufferView']);
}
if (typeof options !== 'object') {
- throw new errors.TypeError('ERR_INVALID_ARG_TYPE', 'options', 'object');
+ throw new errors.TypeError('ERR_INVALID_ARG_TYPE', 'options', 'Object');
}
var flags = 0;
@@ -417,7 +417,7 @@ function makeTextDecoderJS() {
constructor(encoding = 'utf-8', options = {}) {
encoding = `${encoding}`;
if (typeof options !== 'object')
- throw new errors.Error('ERR_INVALID_ARG_TYPE', 'options', 'object');
+ throw new errors.Error('ERR_INVALID_ARG_TYPE', 'options', 'Object');
const enc = getEncodingFromLabel(encoding);
if (enc === undefined || !hasConverter(enc))
@@ -452,7 +452,7 @@ function makeTextDecoderJS() {
['ArrayBuffer', 'ArrayBufferView']);
}
if (typeof options !== 'object') {
- throw new errors.TypeError('ERR_INVALID_ARG_TYPE', 'options', 'object');
+ throw new errors.TypeError('ERR_INVALID_ARG_TYPE', 'options', 'Object');
}
if (this[kFlags] & CONVERTER_FLAGS_FLUSH) {