Skip to content

Commit

Permalink
util: deleted unreachable code from util.inspect
Browse files Browse the repository at this point in the history
PR-URL: #24187
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
  • Loading branch information
kiyomizumia authored and codebytere committed Jan 12, 2019
1 parent 8a60798 commit 7576a51
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions lib/internal/util/inspect.js
Original file line number Diff line number Diff line change
Expand Up @@ -259,9 +259,8 @@ function strEscape(str) {
last = i + 1;
}
}
if (last === 0) {
result = str;
} else if (last !== i) {

if (last !== i) {
result += str.slice(last);
}
return `'${result}'`;
Expand Down

0 comments on commit 7576a51

Please sign in to comment.