diff --git a/typings/index.d.ts b/typings/index.d.ts index 2c93e2475..d79e51123 100644 --- a/typings/index.d.ts +++ b/typings/index.d.ts @@ -2643,8 +2643,7 @@ export class ApplicationCommandManager< null >; private commandPath({ id, guildId }: { id?: Snowflake; guildId?: Snowflake }): unknown; - public create(command: ApplicationCommandDataResolvable): Promise; - public create(command: ApplicationCommandDataResolvable, guildId: Snowflake): Promise; + public create(command: ApplicationCommandDataResolvable, guildId?: Snowflake): Promise; public delete(command: ApplicationCommandResolvable, guildId?: Snowflake): Promise; public edit( command: ApplicationCommandResolvable, diff --git a/typings/tests.ts b/typings/tests.ts index fe494f5d6..f132aff7b 100644 --- a/typings/tests.ts +++ b/typings/tests.ts @@ -794,7 +794,8 @@ declare const applicationCommandManager: ApplicationCommandManager; type ApplicationCommandScope = ApplicationCommand<{ guild: GuildResolvable }>; assertType>(applicationCommandManager.create(applicationCommandData)); - assertType>(applicationCommandManager.create(applicationCommandData, '0')); + assertType>(applicationCommandManager.create(applicationCommandData, '0')); + assertType>(applicationCommandManager.create(applicationCommandData, undefined)); assertType>( applicationCommandManager.edit(applicationCommandResolvable, applicationCommandData), );