diff options
author | Sam Roberts <sam@strongloop.com> | 2014-07-05 14:22:45 -0700 |
---|---|---|
committer | Fedor Indutny <fedor@indutny.com> | 2014-07-07 08:44:40 +0300 |
commit | e2f2a202791293f2152a382852885bfd5eaf87e4 (patch) | |
tree | 53fe618b367b4ae1c9bac85aba6f96fa6701725e | |
parent | 11337db35f6826c3f8f4c76eafd5ebf1c17294d7 (diff) | |
download | node-new-e2f2a202791293f2152a382852885bfd5eaf87e4.tar.gz |
doc: fix console.assert docs, message is a format
Documentation for console.assert incorrectly described message as a
single message, but it is a format.
Signed-off-by: Fedor Indutny <fedor@indutny.com>
-rw-r--r-- | doc/api/console.markdown | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/doc/api/console.markdown b/doc/api/console.markdown index e53902f7ad..e7807feeaf 100644 --- a/doc/api/console.markdown +++ b/doc/api/console.markdown @@ -66,10 +66,10 @@ Finish timer, record output. Example: Print a stack trace to stderr of the current position. -## console.assert(expression, [message]) +## console.assert(value, [message], [...]) -Same as [assert.ok()][] where if the `expression` evaluates as `false` throw an -AssertionError with `message`. +Similar to [assert.ok()][], but the error message is formatted as +`util.format(message...)`. [assert.ok()]: assert.html#assert_assert_value_message_assert_ok_value_message [util.format()]: util.html#util_util_format_format |