@stonyx/discord 0.1.1-beta.49 → 0.1.1-beta.50
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/dist/bot.js +4 -0
- package/package.json +1 -1
package/dist/bot.js
CHANGED
|
@@ -17,6 +17,10 @@ export default class DiscordBot {
|
|
|
17
17
|
DiscordBot.instance = this;
|
|
18
18
|
}
|
|
19
19
|
async init() {
|
|
20
|
+
// Self-register so log.discord works even when @stonyx/discord is in the
|
|
21
|
+
// consumer's `dependencies` (stonyx loader only merges devDependencies).
|
|
22
|
+
const { logColor = '#7289da', logMethod = 'discord' } = config.discord;
|
|
23
|
+
log.defineType(logMethod, logColor);
|
|
20
24
|
if (this.client) {
|
|
21
25
|
// Already initialized — singleton reuse via Discord.init() or a direct
|
|
22
26
|
// new DiscordBot().init() call. Wait for the existing ready promise
|