From 96a065560990a5fd06e7bdf38c62502dcba71b9a Mon Sep 17 00:00:00 2001 From: bdistin Date: Mon, 1 Oct 2018 05:43:08 -0500 Subject: [PATCH] refactor(WebhookClient): make token property non-enumerable (#2861) * make WebhookClient#token non-enumerable parity with Client to add the barest protection against accidental exposure * requested change --- src/client/WebhookClient.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/client/WebhookClient.js b/src/client/WebhookClient.js index c4c297879..0a848d808 100644 --- a/src/client/WebhookClient.js +++ b/src/client/WebhookClient.js @@ -20,7 +20,7 @@ class WebhookClient extends BaseClient { super(options); Object.defineProperty(this, 'client', { value: this }); this.id = id; - this.token = token; + Object.defineProperty(this, 'token', { value: token, writable: true, configurable: true }); } }