@somehiddenkey/discord-command-utils 2.7.0 → 2.7.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -10,29 +10,26 @@ export default class LocalConfig {
|
|
|
10
10
|
/** @type {string?} */
|
|
11
11
|
prefix;
|
|
12
12
|
/** @type {Snowflake} */
|
|
13
|
-
|
|
13
|
+
client_id;
|
|
14
14
|
|
|
15
15
|
/** @type {object} */
|
|
16
16
|
local;
|
|
17
17
|
/** @type {object} */
|
|
18
|
-
|
|
18
|
+
rest_options;
|
|
19
19
|
/** @type {object} */
|
|
20
20
|
activity;
|
|
21
21
|
|
|
22
22
|
constructor(data) {
|
|
23
23
|
this.prefix = data.prefix;
|
|
24
|
-
this
|
|
24
|
+
this.client_id = data.client_id;
|
|
25
25
|
this.local = data.local || {};
|
|
26
|
-
this
|
|
26
|
+
this.rest_options = data.rest_options || {};
|
|
27
27
|
this.activity = data.activity || {};
|
|
28
28
|
|
|
29
|
-
if(!this
|
|
29
|
+
if(!this.client_id)
|
|
30
30
|
throw new ConfigError('No client_id initialized for LocalConfig');
|
|
31
31
|
}
|
|
32
32
|
|
|
33
|
-
get clientId() { return this.#client_id; }
|
|
34
|
-
get restOptions() { return this.#rest_options; }
|
|
35
|
-
|
|
36
33
|
/**
|
|
37
34
|
* Loads the JSON file and returns a GlobalConfig instance.
|
|
38
35
|
* @param {string} path
|