Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 2e81795

Browse filesBrowse files
committed
lib: enforce use of Boolean from primordials
Refs: #30697 PR-URL: #30698 Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Yongsheng Zhang <zyszys98@gmail.com>
1 parent 61bb7b9 commit 2e81795
Copy full SHA for 2e81795

File tree

Expand file treeCollapse file tree

9 files changed

+20
-0
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

9 files changed

+20
-0
lines changed
Open diff view settings
Collapse file

‎lib/.eslintrc.yaml‎

Copy file name to clipboardExpand all lines: lib/.eslintrc.yaml
+2Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ rules:
1111
- error
1212
- name: Array
1313
message: "Use `const { Array } = primordials;` instead of the global."
14+
- name: Boolean
15+
message: "Use `const { Boolean } = primordials;` instead of the global."
1416
- name: JSON
1517
message: "Use `const { JSON } = primordials;` instead of the global."
1618
- name: Math
Collapse file

‎lib/_http_client.js‎

Copy file name to clipboardExpand all lines: lib/_http_client.js
+1Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323

2424
const {
2525
ArrayIsArray,
26+
Boolean,
2627
ObjectAssign,
2728
ObjectKeys,
2829
ObjectSetPrototypeOf,
Collapse file

‎lib/internal/cluster/round_robin_handle.js‎

Copy file name to clipboardExpand all lines: lib/internal/cluster/round_robin_handle.js
+5Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,9 @@
11
'use strict';
2+
3+
const {
4+
Boolean,
5+
} = primordials;
6+
27
const assert = require('internal/assert');
38
const net = require('net');
49
const { sendHelper } = require('internal/cluster/utils');
Collapse file

‎lib/internal/console/constructor.js‎

Copy file name to clipboardExpand all lines: lib/internal/console/constructor.js
+1Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
const {
77
ArrayFrom,
88
ArrayIsArray,
9+
Boolean,
910
ObjectDefineProperties,
1011
ObjectDefineProperty,
1112
ObjectKeys,
Collapse file

‎lib/internal/http2/compat.js‎

Copy file name to clipboardExpand all lines: lib/internal/http2/compat.js
+1Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
const {
44
ArrayIsArray,
5+
Boolean,
56
ObjectAssign,
67
ObjectCreate,
78
ObjectKeys,
Collapse file

‎lib/internal/readline/utils.js‎

Copy file name to clipboardExpand all lines: lib/internal/readline/utils.js
+4Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
'use strict';
22

3+
const {
4+
Boolean,
5+
} = primordials;
6+
37
// Regex used for ansi escape code splitting
48
// Adopted from https://github.com/chalk/ansi-regex/blob/master/index.js
59
// License: MIT, authors: @sindresorhus, Qix-, and arjunmehta
Collapse file

‎lib/internal/repl/history.js‎

Copy file name to clipboardExpand all lines: lib/internal/repl/history.js
+4Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
'use strict';
22

3+
const {
4+
Boolean,
5+
} = primordials;
6+
37
const { Interface } = require('readline');
48
const path = require('path');
59
const fs = require('fs');
Collapse file

‎lib/net.js‎

Copy file name to clipboardExpand all lines: lib/net.js
+1Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323

2424
const {
2525
ArrayIsArray,
26+
Boolean,
2627
ObjectDefineProperty,
2728
ObjectSetPrototypeOf,
2829
} = primordials;
Collapse file

‎lib/perf_hooks.js‎

Copy file name to clipboardExpand all lines: lib/perf_hooks.js
+1Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
const {
44
ArrayIsArray,
5+
Boolean,
56
ObjectDefineProperties,
67
ObjectDefineProperty,
78
ObjectKeys,

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.