util: deleted unreachable code from util.inspect

PR-URL: https://github.com/nodejs/node/pull/24187
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
This commit is contained in:
kiyomizumia 2018-11-06 16:57:19 +00:00 committed by Gireesh Punathil
parent 7067572a63
commit 531d854458

View File

@ -297,9 +297,8 @@ function strEscape(str) {
last = i + 1;
}
}
if (last === 0) {
result = str;
} else if (last !== i) {
if (last !== i) {
result += str.slice(last);
}
return addQuotes(result, singleQuote);