util: runtime deprecate util.log

fix pr url

PR-URL: https://github.com/nodejs/node/pull/50488
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
Reviewed-By: Yagiz Nizipli <yagiz.nizipli@sentry.io>
Reviewed-By: Robert Nagy <ronagy@icloud.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
This commit is contained in:
Marco Ippolito 2023-10-31 13:04:21 +02:00 committed by Node.js GitHub Bot
parent 6cf20d5e43
commit e96cd25007
2 changed files with 8 additions and 2 deletions

View File

@ -1313,6 +1313,9 @@ The [`util.isUndefined()`][] API is deprecated.
<!-- YAML
changes:
- version: REPLACEME
pr-url: https://github.com/nodejs/node/pull/50488
description: Runtime deprecation.
- version: v6.12.0
pr-url: https://github.com/nodejs/node/pull/10116
description: A deprecation code has been assigned.
@ -1321,7 +1324,7 @@ changes:
description: Documentation-only deprecation.
-->
Type: Documentation-only
Type: Runtime
The [`util.log()`][] API is deprecated.

View File

@ -446,7 +446,10 @@ module.exports = {
'Please use `arg === null || ' +
'(typeof arg !== "object" && typeof arg !== "function")` instead.',
'DEP0054'),
log: deprecate(log, 'The `util.log API is deprecated.', 'DEP0059'),
log: deprecate(log,
'The `util.log API is deprecated. ' +
'Please use console.log() with a custom formatter or a third-party logger instead.',
'DEP0059'),
promisify,
stripVTControlCharacters,
toUSVString,