@@ -39,6 +39,7 @@ export interface CommandOptions {
39
39
description ?: string ;
40
40
descriptionLocalizations ?: Record < LocaleString , string > ;
41
41
type : Array < CommandType | keyof typeof CommandType > ;
42
+ category ?: string ;
42
43
defaultMemberPermissions ?: PermissionResolvable ;
43
44
dmPermission ?: boolean ;
44
45
arguments ?: Array < Argument | ArgumentOptions > ;
@@ -88,6 +89,7 @@ const validationSchema = z
88
89
)
89
90
. array ( )
90
91
. nonempty ( ) ,
92
+ category : z . string ( ) . optional ( ) ,
91
93
defaultMemberPermissions : z . any ( ) . optional ( ) ,
92
94
dmPermission : z . boolean ( ) . optional ( ) ,
93
95
arguments : z . any ( ) . array ( ) . optional ( ) ,
@@ -115,6 +117,7 @@ export class Command {
115
117
public description ?: string ;
116
118
public descriptionLocalizations ?: Record < LocaleString , string > ;
117
119
public type : Array < CommandType | keyof typeof CommandType > ;
120
+ public category ?: string ;
118
121
public defaultMemberPermissions ?: PermissionResolvable ;
119
122
public dmPermission ?: boolean ;
120
123
public arguments ?: Array < Argument > ;
@@ -155,6 +158,7 @@ export class Command {
155
158
} ) ;
156
159
this . inhibitors = options . inhibitors || Command . defaults ?. inhibitors ;
157
160
this . guildId = options . guildId || Command . defaults ?. guildId ;
161
+ this . category = options . category ;
158
162
this . cooldown = options . cooldown || Command . defaults ?. cooldown ;
159
163
this . fileName = options . fileName || Command . defaults ?. fileName ;
160
164
this . run = options . run || Command . defaults ?. run ;
0 commit comments