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
This commit is contained in:
bdistin
2018-10-01 05:43:08 -05:00
committed by SpaceEEC
parent d8c97be142
commit 96a0655609

View File

@@ -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 });
}
}