Skip to content

Commit 47af0a0

Browse files
addaleaxjasnell
authored andcommitted
Revert "util: change %o depth default"
This reverts commit 8f15309. PR-URL: #20089 Reviewed-By: Joyee Cheung <[email protected]> Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Gus Caplan <[email protected]>
1 parent 1f01112 commit 47af0a0

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

doc/api/util.md

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -182,9 +182,6 @@ property take precedence over `--trace-deprecation` and
182182
<!-- YAML
183183
added: v0.5.3
184184
changes:
185-
- version: REPLACEME
186-
pr-url: https://github.com/nodejs/node/pull/17907
187-
description: The `%o` specifiers `depth` option is now set to Infinity.
188185
- version: v8.4.0
189186
pr-url: https://github.com/nodejs/node/pull/14558
190187
description: The `%o` and `%O` specifiers are supported now.

lib/util.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,8 @@ function formatWithOptions(inspectOptions, f) {
218218
{
219219
const opts = Object.assign({}, inspectOptions, {
220220
showHidden: true,
221-
showProxy: true
221+
showProxy: true,
222+
depth: 4
222223
});
223224
tempStr = inspect(arguments[a++], opts);
224225
break;

0 commit comments

Comments
 (0)