process,doc: add missing deprecation code

Refs: https://github.com/nodejs/node/pull/36902

PR-URL: https://github.com/nodejs/node/pull/37091
Reviewed-By: Zijian Liu <lxxyxzj@gmail.com>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
This commit is contained in:
cjihrig authored and Antoine du Hamel committed 2021-01-27 11:57:48 +01:00
1 parent 2e1e02a77a
commit 4e833b6059
2 files changed
+2 -2

No files matched your search

+1 -1
View File
@@ -2711,7 +2711,7 @@ Type: Documentation-only.
Prefer [`message.socket`][] over [`message.connection`][].
### DEP0XXX: Changing the value of `process.config`
### DEP0150: Changing the value of `process.config`
<!-- YAML
changes:
- version: REPLACEME
+1 -1
View File
@@ -72,7 +72,7 @@ const deprecationHandler = {
warned: false,
message: 'Setting process.config is deprecated. ' +
'In the future the property will be read-only.',
code: 'DEP0XXX',
code: 'DEP0150',
maybeWarn() {
if (!this.warned) {
process.emitWarning(this.message, {