From b687f17bd62fbfffd328ef5d1b1d38ea95b29bef Mon Sep 17 00:00:00 2001 From: Natanael Log Date: Sat, 1 Jul 2017 15:10:36 +0200 Subject: [PATCH 1/2] doc, util, console: clarify ambiguous docs Add clarification to the documentation on util.format() and console.log() regarding how excessive arguments are treated when the first argument is a non-format string compared to when it is not a string at all. Fixes: https://github.com/nodejs/node/issues/13908 --- doc/api/console.md | 4 +--- doc/api/util.md | 9 ++++++++- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/doc/api/console.md b/doc/api/console.md index 3411d3ce0afba2..4939ed77bef1b8 100644 --- a/doc/api/console.md +++ b/doc/api/console.md @@ -246,9 +246,7 @@ console.log('count:', count); // Prints: count: 5, to stdout ``` -If formatting elements (e.g. `%d`) are not found in the first string then -[`util.inspect()`][] is called on each argument and the resulting string -values are concatenated. See [`util.format()`][] for more information. +See [`util.format()`][] for more information. ### console.time(label)