Clean up a bunch of stuff

- Channel typing data is now a Map
- Client properties on structures are now non-enumerable and
non-configurable
This commit is contained in:
Schuyler Cebulskie
2016-09-07 00:24:45 -04:00
parent 3a790e74f4
commit b7f582b7f0
22 changed files with 411 additions and 316 deletions

View File

@@ -14,6 +14,8 @@ class PartialGuildChannel {
* @type {Client}
*/
this.client = client;
Object.defineProperty(this, 'client', { enumerable: false, configurable: false });
this.setup(data);
}
@@ -23,11 +25,13 @@ class PartialGuildChannel {
* @type {string}
*/
this.id = data.id;
/**
* The name of this Guild Channel
* @type {string}
*/
this.name = data.name;
/**
* The type of this Guild Channel - `text` or `voice`
* @type {string}