From 0646eda4fc0affb98e13c30acb522e63b7fd6dde Mon Sep 17 00:00:00 2001 From: Michaƫl Zasso Date: Fri, 22 Nov 2019 18:04:46 +0100 Subject: lib: flatten access to primordials Store all primordials as properties of the primordials object. Static functions are prefixed by the constructor's name and prototype methods are prefixed by the constructor's name followed by "Prototype". For example: primordials.Object.keys becomes primordials.ObjectKeys. PR-URL: https://github.com/nodejs/node/pull/30610 Refs: https://github.com/nodejs/node/issues/29766 Reviewed-By: Anna Henningsen Reviewed-By: Matteo Collina Reviewed-By: Colin Ihrig Reviewed-By: Trivikram Kamat --- lib/_http_agent.js | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'lib/_http_agent.js') diff --git a/lib/_http_agent.js b/lib/_http_agent.js index 270569eab9..af25b2bba7 100644 --- a/lib/_http_agent.js +++ b/lib/_http_agent.js @@ -22,11 +22,9 @@ 'use strict'; const { - Object: { - setPrototypeOf: ObjectSetPrototypeOf, - keys: ObjectKeys, - values: ObjectValues - } + ObjectKeys, + ObjectSetPrototypeOf, + ObjectValues, } = primordials; const net = require('net'); -- cgit v1.2.3