An AddSlashCommand overload should be AddAutocompleteCommand in ModuleBuilder (#3014)
This commit is contained in:
@@ -371,6 +371,11 @@ namespace Discord.Interactions.Builders
|
|||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <inheritdoc cref="Discord.Interactions.Builders.ModuleBuilder.AddAutocompleteCommand(System.String,Discord.Interactions.ExecuteCallback,System.Action{Discord.Interactions.Builders.AutocompleteCommandBuilder})" />
|
||||||
|
[Obsolete("This method will be deprecated soon. Use AddAutocompleteCommand instead.")]
|
||||||
|
public ModuleBuilder AddSlashCommand(string name, ExecuteCallback callback, Action<AutocompleteCommandBuilder> configure)
|
||||||
|
=> AddAutocompleteCommand(name, callback, configure);
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Adds autocomplete command builder to <see cref="AutocompleteCommands"/>.
|
/// Adds autocomplete command builder to <see cref="AutocompleteCommands"/>.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@@ -380,7 +385,7 @@ namespace Discord.Interactions.Builders
|
|||||||
/// <returns>
|
/// <returns>
|
||||||
/// The builder instance.
|
/// The builder instance.
|
||||||
/// </returns>
|
/// </returns>
|
||||||
public ModuleBuilder AddSlashCommand(string name, ExecuteCallback callback, Action<AutocompleteCommandBuilder> configure)
|
public ModuleBuilder AddAutocompleteCommand(string name, ExecuteCallback callback, Action<AutocompleteCommandBuilder> configure)
|
||||||
{
|
{
|
||||||
var command = new AutocompleteCommandBuilder(this, name, callback);
|
var command = new AutocompleteCommandBuilder(this, name, callback);
|
||||||
configure(command);
|
configure(command);
|
||||||
|
|||||||
Reference in New Issue
Block a user