summaryrefslogtreecommitdiff
path: root/lib/internal/streams/state.js
diff options
context:
space:
mode:
Diffstat (limited to 'lib/internal/streams/state.js')
-rw-r--r--lib/internal/streams/state.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/internal/streams/state.js b/lib/internal/streams/state.js
index aa16a0a6b8..fa902ef429 100644
--- a/lib/internal/streams/state.js
+++ b/lib/internal/streams/state.js
@@ -2,6 +2,7 @@
const {
MathFloor,
+ NumberIsInteger,
} = primordials;
const { ERR_INVALID_OPT_VALUE } = require('internal/errors').codes;
@@ -18,7 +19,7 @@ function getDefaultHighWaterMark(objectMode) {
function getHighWaterMark(state, options, duplexKey, isDuplex) {
const hwm = highWaterMarkFrom(options, isDuplex, duplexKey);
if (hwm != null) {
- if (!Number.isInteger(hwm) || hwm < 0) {
+ if (!NumberIsInteger(hwm) || hwm < 0) {
const name = isDuplex ? duplexKey : 'highWaterMark';
throw new ERR_INVALID_OPT_VALUE(name, hwm);
}