vimcord 1.0.43 → 1.0.45

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/index.cjs CHANGED
@@ -1021,7 +1021,7 @@ var VimcordCLI = class _VimcordCLI {
1021
1021
  if (mode === "on") {
1022
1022
  CLI.logger.log(`~ Type ${CLI.options.prefix}help to view available commands`);
1023
1023
  } else {
1024
- CLI.logger.log(`~ [MODE] Now set to "${mode}"`);
1024
+ CLI.logger.log(`~ Updated mode to "${mode}"`);
1025
1025
  }
1026
1026
  }
1027
1027
  rl;
@@ -1787,7 +1787,7 @@ var VimcordErrorHandler = class {
1787
1787
  var import_chalk2 = __toESM(require("chalk"));
1788
1788
 
1789
1789
  // package.json
1790
- var version = "1.0.42";
1790
+ var version = "1.0.45";
1791
1791
 
1792
1792
  // src/client/vimcord.logger.ts
1793
1793
  var clientLoggerFactory = (client) => new Logger({ prefixEmoji: "\u26A1", prefix: `vimcord (i${client.clientId})` }).extend({
@@ -2731,19 +2731,11 @@ var Vimcord = class _Vimcord extends import_discord11.Client {
2731
2731
  this.features = features;
2732
2732
  this.config = defineVimcordConfig(config);
2733
2733
  this.error = new VimcordErrorHandler(this);
2734
- if (this.features.useGlobalErrorHandlers) {
2735
- this.error.setupGlobalHandlers();
2736
- }
2737
2734
  this.status = new StatusManager(this);
2738
2735
  this.events = new EventManager(this);
2739
2736
  this.commands = new CommandManager(this);
2740
- this.configure("app", this.config.app);
2741
- this.logger.clientBanner(this);
2742
2737
  this.once("clientReady", (client) => this.logger.clientReady(client.user.tag, client.guilds.cache.size));
2743
2738
  _Vimcord.instances.set(this.clientId, this);
2744
- if (this.config.app.enableCLI) {
2745
- VimcordCLI.setMode("on");
2746
- }
2747
2739
  }
2748
2740
  /** Builds the client by importing modules and registering builtin handlers. */
2749
2741
  async build() {
@@ -2752,14 +2744,8 @@ var Vimcord = class _Vimcord extends import_discord11.Client {
2752
2744
  this.configure("slashCommands", this.config.slashCommands);
2753
2745
  this.configure("prefixCommands", this.config.prefixCommands);
2754
2746
  this.configure("contextCommands", this.config.contextCommands);
2755
- if (this.features.importModules) {
2756
- const importModules = this.features.importModules;
2757
- await Promise.all([
2758
- importModules.events && this.importModules("events", importModules.events),
2759
- importModules.slashCommands && this.importModules("slashCommands", importModules.slashCommands),
2760
- importModules.prefixCommands && this.importModules("prefixCommands", importModules.prefixCommands),
2761
- importModules.contextCommands && this.importModules("contextCommands", importModules.contextCommands)
2762
- ]);
2747
+ if (this.features.useGlobalErrorHandlers) {
2748
+ this.error.setupGlobalHandlers();
2763
2749
  }
2764
2750
  if (this.features.useDefaultSlashCommandHandler) {
2765
2751
  this.events.register(slashCommandHandler);
@@ -2770,6 +2756,18 @@ var Vimcord = class _Vimcord extends import_discord11.Client {
2770
2756
  if (this.features.useDefaultPrefixCommandHandler) {
2771
2757
  this.events.register(prefixCommandHandler);
2772
2758
  }
2759
+ if (this.features.importModules) {
2760
+ const importModules = this.features.importModules;
2761
+ await Promise.all([
2762
+ importModules.events && this.importModules("events", importModules.events),
2763
+ importModules.slashCommands && this.importModules("slashCommands", importModules.slashCommands),
2764
+ importModules.prefixCommands && this.importModules("prefixCommands", importModules.prefixCommands),
2765
+ importModules.contextCommands && this.importModules("contextCommands", importModules.contextCommands)
2766
+ ]);
2767
+ }
2768
+ if (this.config.app.enableCLI) {
2769
+ VimcordCLI.setMode("on");
2770
+ }
2773
2771
  return this;
2774
2772
  }
2775
2773
  /** Current app name */
@@ -2882,6 +2880,7 @@ var Vimcord = class _Vimcord extends import_discord11.Client {
2882
2880
  );
2883
2881
  }
2884
2882
  await this.build();
2883
+ this.logger.clientBanner(this);
2885
2884
  try {
2886
2885
  const stopLoader = this.logger.loader("Connecting to Discord...");
2887
2886
  const loginResult = await import_qznt4.$.async.retry(() => super.login(token), {
@@ -2889,7 +2888,7 @@ var Vimcord = class _Vimcord extends import_discord11.Client {
2889
2888
  delay: 1e3
2890
2889
  });
2891
2890
  stopLoader("Connected to Discord ");
2892
- this.$verboseMode && this.logger.debug("Waiting for ready...");
2891
+ this.logger.debug("Waiting for the client to be ready...");
2893
2892
  if (typeof tokenOrPreHook === "function") {
2894
2893
  await tokenOrPreHook(this);
2895
2894
  } else {