@pikokr/command.ts 3.0.8-dev.3955b1f → 3.0.8-dev.3c7dd97

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.
@@ -7,7 +7,7 @@ export declare class CommandCheckFailed extends Error {
7
7
  constructor(msg: Message, command: Command);
8
8
  }
9
9
  export declare class SlashCommandCheckFailed extends Error {
10
- msg: CommandInteraction;
10
+ interaction: CommandInteraction;
11
11
  command: SlashCommand;
12
- constructor(msg: CommandInteraction, command: SlashCommand);
12
+ constructor(interaction: CommandInteraction, command: SlashCommand);
13
13
  }
@@ -10,9 +10,9 @@ class CommandCheckFailed extends Error {
10
10
  }
11
11
  exports.CommandCheckFailed = CommandCheckFailed;
12
12
  class SlashCommandCheckFailed extends Error {
13
- constructor(msg, command) {
13
+ constructor(interaction, command) {
14
14
  super();
15
- this.msg = msg;
15
+ this.interaction = interaction;
16
16
  this.command = command;
17
17
  }
18
18
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@pikokr/command.ts",
3
3
  "description": "Discord.js command framework for typescript.",
4
- "version": "3.0.8-dev.3955b1f",
4
+ "version": "3.0.8-dev.3c7dd97",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
7
7
  "license": "MIT",
@@ -9,7 +9,7 @@ export class CommandCheckFailed extends Error {
9
9
  }
10
10
 
11
11
  export class SlashCommandCheckFailed extends Error {
12
- constructor(public msg: CommandInteraction, public command: SlashCommand) {
12
+ constructor(public interaction: CommandInteraction, public command: SlashCommand) {
13
13
  super()
14
14
  }
15
15
  }
@@ -8,7 +8,7 @@ export class Dev extends BuiltInModule {
8
8
  }
9
9
 
10
10
  @listener('slashCommandError')
11
- async slashError(e: Error, i: CommandInteraction) {
11
+ slashError(e: Error, i: CommandInteraction) {
12
12
  if (e instanceof SlashCommandCheckFailed) {
13
13
  return i.reply({
14
14
  content: 'Command before-run check failed',