seyfert 3.2.7-dev-18548837005.0 → 3.2.7-dev-18661561926.0

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.
@@ -1,4 +1,4 @@
1
- export declare const DefaultUserAgent = "DiscordBot (https://seyfert.dev, v3.2.5)";
1
+ export declare const DefaultUserAgent: "DiscordBot (https://seyfert.dev, v3.2.5)";
2
2
  export declare const ALLOWED_EXTENSIONS: readonly ["webp", "png", "jpg", "jpeg", "gif"];
3
3
  export declare const ALLOWED_STICKER_EXTENSIONS: readonly ["png", "json", "gif"];
4
4
  export declare const ALLOWED_SIZES: readonly [16, 32, 64, 100, 128, 256, 512, 1024, 2048, 4096];
@@ -15,7 +15,8 @@ import type { Thumbnail } from './Thumbnail';
15
15
  export type ComponentCallback<T extends ComponentInteraction | StringSelectMenuInteraction = ComponentInteraction | StringSelectMenuInteraction> = (interaction: T, stop: ComponentStopCallback, refresh: ComponentRefreshCallback) => any;
16
16
  export type ComponentOnErrorCallback<T extends ComponentInteraction | StringSelectMenuInteraction = ComponentInteraction | StringSelectMenuInteraction> = (interaction: T, error: unknown, stop: ComponentStopCallback, refresh: ComponentRefreshCallback) => any;
17
17
  export type ComponentFilterCallback<T = ComponentInteraction> = (interaction: T) => any;
18
- export type ComponentStopCallback = (reason: 'messageDelete' | 'channelDelete' | 'guildDelete' | 'idle' | 'timeout' | (string & {}) | undefined, refresh: ComponentRefreshCallback) => any;
18
+ export type ComponentOnStopCallback = (reason: 'messageDelete' | 'channelDelete' | 'guildDelete' | 'idle' | 'timeout' | (string & {}) | undefined, refresh: ComponentRefreshCallback) => any;
19
+ export type ComponentStopCallback = (reason: 'messageDelete' | 'channelDelete' | 'guildDelete' | 'idle' | 'timeout' | (string & {}) | undefined) => any;
19
20
  export type ComponentRefreshCallback = () => any;
20
21
  export type ModalSubmitCallback<T = ModalSubmitInteraction> = (interaction: T) => any;
21
22
  export type ButtonLink = Omit<Button, 'setCustomId'>;
@@ -31,6 +32,6 @@ export interface ListenerOptions {
31
32
  idle?: number;
32
33
  filter?: ComponentFilterCallback;
33
34
  onPass?: ComponentFilterCallback;
34
- onStop?: ComponentStopCallback;
35
+ onStop?: ComponentOnStopCallback;
35
36
  onError?: ComponentOnErrorCallback;
36
37
  }
@@ -1,4 +1,4 @@
1
- import type { ComponentCallback, ComponentOnErrorCallback, ListenerOptions, ModalSubmitCallback } from '../builders/types';
1
+ import { ComponentCallback, ComponentOnErrorCallback, ListenerOptions, ModalSubmitCallback } from '../builders/types';
2
2
  import { LimitedCollection } from '../collection';
3
3
  import { type UsingClient } from '../commands';
4
4
  import type { FileLoaded } from '../commands/handler';
@@ -63,7 +63,10 @@ class EventHandler extends common_1.BaseHandler {
63
63
  }
64
64
  async load(eventsDir) {
65
65
  const paths = await this.loadFilesK(await this.getFiles(eventsDir));
66
- for (const { events, file } of paths.map(x => ({ events: this.onFile(x.file), file: x }))) {
66
+ for (const { events, file } of paths.map(x => ({
67
+ events: this.onFile(x.file),
68
+ file: x,
69
+ }))) {
67
70
  if (!events)
68
71
  continue;
69
72
  for (const i of events) {
@@ -194,7 +197,7 @@ class EventHandler extends common_1.BaseHandler {
194
197
  return this.client.collectors.run(name, args, this.client);
195
198
  }
196
199
  Event.fired = true;
197
- this.logger.debug(`executed a custom event [${name}]`, Event.data.once ? 'once' : '');
200
+ this.client.debugger?.debug(`executed a custom event [${name}]`, Event.data.once ? 'once' : '');
198
201
  await Promise.all([
199
202
  Event.run(...args, this.client),
200
203
  // @ts-expect-error
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "seyfert",
3
- "version": "3.2.7-dev-18548837005.0",
3
+ "version": "3.2.7-dev-18661561926.0",
4
4
  "description": "The most advanced framework for discord bots",
5
5
  "main": "./lib/index.js",
6
6
  "module": "./lib/index.js",