From 94fbb24f94910b905e2aea793fbf4740d9cfca28 Mon Sep 17 00:00:00 2001 From: Charmander <~@charmander.me> Date: Thu, 30 Jan 2020 04:58:29 -0800 Subject: [PATCH] Make native client password property consistent with others i.e. configurable. --- packages/pg/lib/native/client.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/pg/lib/native/client.js b/packages/pg/lib/native/client.js index d06166573..ba9d141eb 100644 --- a/packages/pg/lib/native/client.js +++ b/packages/pg/lib/native/client.js @@ -46,11 +46,11 @@ var Client = module.exports = function (config) { // "hiding" the password so it doesn't show up in stack traces // or if the client is console.logged - const hiddenPassword = cp.password Object.defineProperty(this, 'password', { + configurable: true, enumerable: false, writable: true, - value: hiddenPassword + value: cp.password }) this.database = cp.database this.host = cp.host