Skip to content

Commit 7576a51

Browse files
kiyomizumiacodebytere
authored andcommitted
util: deleted unreachable code from util.inspect
PR-URL: #24187 Reviewed-By: Сковорода Никита Андреевич <[email protected]> Reviewed-By: James M Snell <[email protected]> Reviewed-By: Anna Henningsen <[email protected]>
1 parent 8a60798 commit 7576a51

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

lib/internal/util/inspect.js

+2-3
Original file line numberDiff line numberDiff line change
@@ -259,9 +259,8 @@ function strEscape(str) {
259259
last = i + 1;
260260
}
261261
}
262-
if (last === 0) {
263-
result = str;
264-
} else if (last !== i) {
262+
263+
if (last !== i) {
265264
result += str.slice(last);
266265
}
267266
return `'${result}'`;

0 commit comments

Comments
 (0)