readline: remove intermediate variable

This commit removes an extrea intermediate variable. This
makes the call consistent with other uses of validateUint32()
in the codebase.

PR-URL: https://github.com/nodejs/node/pull/31676
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
This commit is contained in:
cjihrig 2020-02-07 10:33:06 -05:00
parent 63f10b9f0d
commit efec6811b6
No known key found for this signature in database
GPG Key ID: 7434390BDBE9B9C5

View File

@ -123,8 +123,7 @@ function Interface(input, output, completer, terminal) {
terminal = input.terminal;
historySize = input.historySize;
if (input.tabSize !== undefined) {
const positive = true;
validateUint32(input.tabSize, 'tabSize', positive);
validateUint32(input.tabSize, 'tabSize', true);
this.tabSize = input.tabSize;
}
removeHistoryDuplicates = input.removeHistoryDuplicates;