Browse Source

Spelling corrections (#215)

pull/1923/head
Simon Hjorthøj GitHub 3 years ago
parent
commit
90986e991d
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
50 changed files with 70 additions and 73 deletions
  1. +1
    -1
      samples/02_commands_framework/Program.cs
  2. +1
    -1
      samples/03_sharded_client/Services/CommandHandlingService.cs
  3. +1
    -1
      src/Discord.Net.Commands/Attributes/AliasAttribute.cs
  4. +1
    -1
      src/Discord.Net.Commands/Builders/ModuleClassBuilder.cs
  5. +1
    -1
      src/Discord.Net.Commands/CommandService.cs
  6. +1
    -1
      src/Discord.Net.Commands/ModuleBase.cs
  7. +1
    -1
      src/Discord.Net.Commands/RunMode.cs
  8. +4
    -4
      src/Discord.Net.Core/Entities/Guilds/IGuild.cs
  9. +1
    -1
      src/Discord.Net.Core/Entities/Interactions/Context Menus/MessageCommandBuilder.cs
  10. +1
    -1
      src/Discord.Net.Core/Entities/Interactions/Context Menus/UserCommandBuilder.cs
  11. +1
    -1
      src/Discord.Net.Core/Entities/Interactions/IApplicationCommandOption.cs
  12. +2
    -2
      src/Discord.Net.Core/Entities/Interactions/IDiscordInteraction.cs
  13. +1
    -1
      src/Discord.Net.Core/Entities/Interactions/IDiscordInteractionData.cs
  14. +2
    -2
      src/Discord.Net.Core/Entities/Interactions/InteractionResponseType.cs
  15. +5
    -5
      src/Discord.Net.Core/Entities/Interactions/Slash Commands/SlashCommandBuilder.cs
  16. +1
    -1
      src/Discord.Net.Core/Entities/Interactions/Slash Commands/SlashCommandProperties.cs
  17. +1
    -1
      src/Discord.Net.Core/Entities/Messages/IMessage.cs
  18. +1
    -1
      src/Discord.Net.Core/Entities/Messages/TimestampTag.cs
  19. +2
    -2
      src/Discord.Net.Core/Entities/Permissions/ChannelPermissions.cs
  20. +1
    -1
      src/Discord.Net.Core/Entities/Permissions/GuildPermissions.cs
  21. +1
    -1
      src/Discord.Net.Core/Entities/Permissions/OverwritePermissions.cs
  22. +1
    -1
      src/Discord.Net.Core/Entities/Stickers/ICustomSticker.cs
  23. +2
    -2
      src/Discord.Net.Core/Extensions/MessageExtensions.cs
  24. +1
    -1
      src/Discord.Net.Core/Format.cs
  25. +2
    -2
      src/Discord.Net.Core/RequestOptions.cs
  26. +0
    -1
      src/Discord.Net.Examples/Core/Entities/Channels/IMessageChannel.Examples.cs
  27. +1
    -1
      src/Discord.Net.Rest/DiscordRestApiClient.cs
  28. +3
    -3
      src/Discord.Net.Rest/Entities/Channels/RestThreadChannel.cs
  29. +4
    -4
      src/Discord.Net.Rest/Entities/Guilds/RestGuild.cs
  30. +0
    -1
      src/Discord.Net.Rest/Entities/Interactions/InteractionHelper.cs
  31. +1
    -1
      src/Discord.Net.Rest/Entities/Messages/CustomSticker.cs
  32. +2
    -2
      src/Discord.Net.Rest/Entities/Messages/RestFollowupMessage.cs
  33. +2
    -2
      src/Discord.Net.Rest/Entities/Messages/RestInteractionMessage.cs
  34. +0
    -1
      src/Discord.Net.Rest/Entities/Webhooks/WebhookHelper.cs
  35. +2
    -2
      src/Discord.Net.Rest/Net/Queue/RequestQueueBucket.cs
  36. +1
    -1
      src/Discord.Net.WebSocket/API/Voice/ReadyEvent.cs
  37. +1
    -1
      src/Discord.Net.WebSocket/Audio/Streams/BufferedWriteStream.cs
  38. +3
    -3
      src/Discord.Net.WebSocket/DiscordSocketClient.cs
  39. +1
    -1
      src/Discord.Net.WebSocket/DiscordSocketConfig.cs
  40. +1
    -1
      src/Discord.Net.WebSocket/Entities/Channels/SocketStageChannel.cs
  41. +1
    -1
      src/Discord.Net.WebSocket/Entities/Guilds/SocketGuild.cs
  42. +1
    -1
      src/Discord.Net.WebSocket/Entities/Interaction/Context Menu Commands/Message Commands/SocketMessageCommandData.cs
  43. +2
    -2
      src/Discord.Net.WebSocket/Entities/Interaction/Message Components/SocketMessageComponent.cs
  44. +1
    -1
      src/Discord.Net.WebSocket/Entities/Interaction/Slash Commands/SocketAutocompleteInteraction.cs
  45. +1
    -1
      src/Discord.Net.WebSocket/Entities/Interaction/Slash Commands/SocketAutocompleteInteractionData.cs
  46. +1
    -1
      src/Discord.Net.WebSocket/Entities/Interaction/Slash Commands/SocketSlashCommandDataOption.cs
  47. +1
    -1
      src/Discord.Net.WebSocket/Entities/Interaction/SocketInteraction.cs
  48. +1
    -1
      src/Discord.Net.WebSocket/Entities/Stickers/SocketCustomSticker.cs
  49. +1
    -1
      test/Discord.Net.Tests.Unit/EmbedBuilderTests.cs
  50. +1
    -1
      test/Discord.Net.Tests.Unit/FormatTests.cs

+ 1
- 1
samples/02_commands_framework/Program.cs View File

@@ -39,7 +39,7 @@ namespace _02_commands_framework
services.GetRequiredService<CommandService>().Log += LogAsync; services.GetRequiredService<CommandService>().Log += LogAsync;


// Tokens should be considered secret data and never hard-coded. // Tokens should be considered secret data and never hard-coded.
// We can read from the environment variable to avoid hardcoding.
// We can read from the environment variable to avoid hard coding.
await client.LoginAsync(TokenType.Bot, Environment.GetEnvironmentVariable("token")); await client.LoginAsync(TokenType.Bot, Environment.GetEnvironmentVariable("token"));
await client.StartAsync(); await client.StartAsync();




+ 1
- 1
samples/03_sharded_client/Services/CommandHandlingService.cs View File

@@ -54,7 +54,7 @@ namespace _03_sharded_client.Services
if (!command.IsSpecified) if (!command.IsSpecified)
return; return;


// the command was succesful, we don't care about this result, unless we want to log that a command succeeded.
// the command was successful, we don't care about this result, unless we want to log that a command succeeded.
if (result.IsSuccess) if (result.IsSuccess)
return; return;




+ 1
- 1
src/Discord.Net.Commands/Attributes/AliasAttribute.cs View File

@@ -16,7 +16,7 @@ namespace Discord.Commands
/// <code language="cs"> /// <code language="cs">
/// [Command("stats")] /// [Command("stats")]
/// [Alias("stat", "info")] /// [Alias("stat", "info")]
/// public async Task GetStatsAsync(IUser user)
/// public <see langword="async"/> Task GetStatsAsync(IUser user)
/// { /// {
/// // ...pull stats /// // ...pull stats
/// } /// }


+ 1
- 1
src/Discord.Net.Commands/Builders/ModuleClassBuilder.cs View File

@@ -291,7 +291,7 @@ namespace Discord.Commands
return reader; return reader;
} }


//We dont have a cached type reader, create one
//We don't have a cached type reader, create one
reader = ReflectionUtils.CreateObject<TypeReader>(typeReaderType.GetTypeInfo(), service, services); reader = ReflectionUtils.CreateObject<TypeReader>(typeReaderType.GetTypeInfo(), service, services);
service.AddTypeReader(paramType, reader, false); service.AddTypeReader(paramType, reader, false);




+ 1
- 1
src/Discord.Net.Commands/CommandService.cs View File

@@ -602,7 +602,7 @@ namespace Discord.Commands
//If we get this far, at least one parse was successful. Execute the most likely overload. //If we get this far, at least one parse was successful. Execute the most likely overload.
var chosenOverload = successfulParses[0]; var chosenOverload = successfulParses[0];
var result = await chosenOverload.Key.ExecuteAsync(context, chosenOverload.Value, services).ConfigureAwait(false); var result = await chosenOverload.Key.ExecuteAsync(context, chosenOverload.Value, services).ConfigureAwait(false);
if (!result.IsSuccess && !(result is RuntimeResult || result is ExecuteResult)) // succesful results raise the event in CommandInfo#ExecuteInternalAsync (have to raise it there b/c deffered execution)
if (!result.IsSuccess && !(result is RuntimeResult || result is ExecuteResult)) // successful results raise the event in CommandInfo#ExecuteInternalAsync (have to raise it there b/c deferred execution)
await _commandExecutedEvent.InvokeAsync(chosenOverload.Key.Command, context, result); await _commandExecutedEvent.InvokeAsync(chosenOverload.Key.Command, context, result);
return result; return result;
} }


+ 1
- 1
src/Discord.Net.Commands/ModuleBase.cs View File

@@ -36,7 +36,7 @@ namespace Discord.Commands
/// Specifies if notifications are sent for mentioned users and roles in the <paramref name="message"/>. /// Specifies if notifications are sent for mentioned users and roles in the <paramref name="message"/>.
/// If <c>null</c>, all mentioned roles and users will be notified. /// If <c>null</c>, all mentioned roles and users will be notified.
/// </param> /// </param>
/// <param name="options">The request options for this async request.</param>
/// <param name="options">The request options for this <see langword="async"/> request.</param>
/// <param name="messageReference">The message references to be included. Used to reply to specific messages.</param> /// <param name="messageReference">The message references to be included. Used to reply to specific messages.</param>
/// <param name="component">The message components to be included with this message. Used for interactions.</param> /// <param name="component">The message components to be included with this message. Used for interactions.</param>
/// <param name="stickers">A collection of stickers to send with the file.</param> /// <param name="stickers">A collection of stickers to send with the file.</param>


+ 1
- 1
src/Discord.Net.Commands/RunMode.cs View File

@@ -8,7 +8,7 @@ namespace Discord.Commands
public enum RunMode public enum RunMode
{ {
/// <summary> /// <summary>
/// The default behaviour set in <see cref="CommandServiceConfig"/>.
/// The default behavior set in <see cref="CommandServiceConfig"/>.
/// </summary> /// </summary>
Default, Default,
/// <summary> /// <summary>


+ 4
- 4
src/Discord.Net.Core/Entities/Guilds/IGuild.cs View File

@@ -609,12 +609,12 @@ namespace Discord
/// </returns> /// </returns>
Task<ITextChannel> GetRulesChannelAsync(CacheMode mode = CacheMode.AllowDownload, RequestOptions options = null); Task<ITextChannel> GetRulesChannelAsync(CacheMode mode = CacheMode.AllowDownload, RequestOptions options = null);
/// <summary> /// <summary>
/// Gets the text channel channel where admins and moderators of Community guilds receive notices from Discord.
/// Gets the text channel where admins and moderators of Community guilds receive notices from Discord.
/// </summary> /// </summary>
/// <param name="mode">The <see cref="CacheMode"/> that determines whether the object should be fetched from cache.</param> /// <param name="mode">The <see cref="CacheMode"/> that determines whether the object should be fetched from cache.</param>
/// <param name="options">The options to be used when sending the request.</param> /// <param name="options">The options to be used when sending the request.</param>
/// <returns> /// <returns>
/// A task that represents the asynchronous get operation. The task result contains the text channel channel where
/// A task that represents the asynchronous get operation. The task result contains the text channel where
/// admins and moderators of Community guilds receive notices from Discord; <see langword="null" /> if none is set. /// admins and moderators of Community guilds receive notices from Discord; <see langword="null" /> if none is set.
/// </returns> /// </returns>
Task<ITextChannel> GetPublicUpdatesChannelAsync(CacheMode mode = CacheMode.AllowDownload, RequestOptions options = null); Task<ITextChannel> GetPublicUpdatesChannelAsync(CacheMode mode = CacheMode.AllowDownload, RequestOptions options = null);
@@ -834,7 +834,7 @@ namespace Discord
/// Downloads all users for this guild if the current list is incomplete. /// Downloads all users for this guild if the current list is incomplete.
/// </summary> /// </summary>
/// <remarks> /// <remarks>
/// This method downloads all users found within this guild throught the Gateway and caches them.
/// This method downloads all users found within this guild through the Gateway and caches them.
/// </remarks> /// </remarks>
/// <returns> /// <returns>
/// A task that represents the asynchronous download operation. /// A task that represents the asynchronous download operation.
@@ -1057,7 +1057,7 @@ namespace Discord
/// A task that represents the asynchronous get operation. The task result contains a read-only collection /// A task that represents the asynchronous get operation. The task result contains a read-only collection
/// of application commands found within the guild. /// of application commands found within the guild.
/// </returns> /// </returns>
Task<IReadOnlyCollection<IApplicationCommand>> GetApplicationCommandsAsync (RequestOptions options = null);
Task<IReadOnlyCollection<IApplicationCommand>> GetApplicationCommandsAsync(RequestOptions options = null);


/// <summary> /// <summary>
/// Gets an application command within this guild with the specified id. /// Gets an application command within this guild with the specified id.


+ 1
- 1
src/Discord.Net.Core/Entities/Interactions/Context Menus/MessageCommandBuilder.cs View File

@@ -13,7 +13,7 @@ namespace Discord
public class MessageCommandBuilder public class MessageCommandBuilder
{ {
/// <summary> /// <summary>
/// Returns the maximun length a commands name allowed by Discord
/// Returns the maximum length a commands name allowed by Discord
/// </summary> /// </summary>
public const int MaxNameLength = 32; public const int MaxNameLength = 32;




+ 1
- 1
src/Discord.Net.Core/Entities/Interactions/Context Menus/UserCommandBuilder.cs View File

@@ -13,7 +13,7 @@ namespace Discord
public class UserCommandBuilder public class UserCommandBuilder
{ {
/// <summary> /// <summary>
/// Returns the maximun length a commands name allowed by Discord
/// Returns the maximum length a commands name allowed by Discord
/// </summary> /// </summary>
public const int MaxNameLength = 32; public const int MaxNameLength = 32;




+ 1
- 1
src/Discord.Net.Core/Entities/Interactions/IApplicationCommandOption.cs View File

@@ -22,7 +22,7 @@ namespace Discord
string Name { get; } string Name { get; }


/// <summary> /// <summary>
/// The discription of this command option, 1-100 character description.
/// The description of this command option, 1-100 character description.
/// </summary> /// </summary>
string Description { get; } string Description { get; }




+ 2
- 2
src/Discord.Net.Core/Entities/Interactions/IDiscordInteraction.cs View File

@@ -74,7 +74,7 @@ namespace Discord
/// <summary> /// <summary>
/// Gets the original response for this interaction. /// Gets the original response for this interaction.
/// </summary> /// </summary>
/// <param name="options">The request options for this async request.</param>
/// <param name="options">The request options for this <see langword="async"/> request.</param>
/// <returns>A <see cref="IUserMessage"/> that represents the initial response.</returns> /// <returns>A <see cref="IUserMessage"/> that represents the initial response.</returns>
Task<IUserMessage> GetOriginalResponseAsync (RequestOptions options = null); Task<IUserMessage> GetOriginalResponseAsync (RequestOptions options = null);


@@ -82,7 +82,7 @@ namespace Discord
/// Edits original response for this interaction. /// Edits original response for this interaction.
/// </summary> /// </summary>
/// <param name="func">A delegate containing the properties to modify the message with.</param> /// <param name="func">A delegate containing the properties to modify the message with.</param>
/// <param name="options">The request options for this async request.</param>
/// <param name="options">The request options for this <see langword="async"/> request.</param>
/// <returns>A <see cref="IUserMessage"/> that represents the initial response.</returns> /// <returns>A <see cref="IUserMessage"/> that represents the initial response.</returns>
Task<IUserMessage> ModifyOriginalResponseAsync (Action<MessageProperties> func, RequestOptions options = null); Task<IUserMessage> ModifyOriginalResponseAsync (Action<MessageProperties> func, RequestOptions options = null);




+ 1
- 1
src/Discord.Net.Core/Entities/Interactions/IDiscordInteractionData.cs View File

@@ -7,7 +7,7 @@ using System.Threading.Tasks;
namespace Discord namespace Discord
{ {
/// <summary> /// <summary>
/// Represents an interface used to specify classes that they are a vaild dataype of a <see cref="IDiscordInteraction"/> class.
/// Represents an interface used to specify classes that they are a vaild data type of a <see cref="IDiscordInteraction"/> class.
/// </summary> /// </summary>
public interface IDiscordInteractionData { } public interface IDiscordInteractionData { }
} }

+ 2
- 2
src/Discord.Net.Core/Entities/Interactions/InteractionResponseType.cs View File

@@ -25,13 +25,13 @@ namespace Discord
/// <summary> /// <summary>
/// ACK a command without sending a message, eating the user's input. /// ACK a command without sending a message, eating the user's input.
/// </summary> /// </summary>
[Obsolete("This response type has been depricated by discord. Either use ChannelMessageWithSource or DeferredChannelMessageWithSource", true)]
[Obsolete("This response type has been deprecated by discord. Either use ChannelMessageWithSource or DeferredChannelMessageWithSource", true)]
Acknowledge = 2, Acknowledge = 2,


/// <summary> /// <summary>
/// Respond with a message, showing the user's input. /// Respond with a message, showing the user's input.
/// </summary> /// </summary>
[Obsolete("This response type has been depricated by discord. Either use ChannelMessageWithSource or DeferredChannelMessageWithSource", true)]
[Obsolete("This response type has been deprecated by discord. Either use ChannelMessageWithSource or DeferredChannelMessageWithSource", true)]
ChannelMessage = 3, ChannelMessage = 3,


/// <summary> /// <summary>


+ 5
- 5
src/Discord.Net.Core/Entities/Interactions/Slash Commands/SlashCommandBuilder.cs View File

@@ -13,7 +13,7 @@ namespace Discord
public class SlashCommandBuilder public class SlashCommandBuilder
{ {
/// <summary> /// <summary>
/// Returns the maximun length a commands name allowed by Discord
/// Returns the maximum length a commands name allowed by Discord
/// </summary> /// </summary>
public const int MaxNameLength = 32; public const int MaxNameLength = 32;
/// <summary> /// <summary>
@@ -178,7 +178,7 @@ namespace Discord
// Discord updated the docs, this regex prevents special characters like @!$%( and s p a c e s.. etc, // Discord updated the docs, this regex prevents special characters like @!$%( and s p a c e s.. etc,
// https://discord.com/developers/docs/interactions/slash-commands#applicationcommand // https://discord.com/developers/docs/interactions/slash-commands#applicationcommand
if (!Regex.IsMatch(name, @"^[\w-]{1,32}$")) if (!Regex.IsMatch(name, @"^[\w-]{1,32}$"))
throw new ArgumentException("Command name cannot contian any special characters or whitespaces!", nameof(name));
throw new ArgumentException("Command name cannot contain any special characters or whitespaces!", nameof(name));


// same with description // same with description
Preconditions.NotNullOrEmpty(description, nameof(description)); Preconditions.NotNullOrEmpty(description, nameof(description));
@@ -213,7 +213,7 @@ namespace Discord
/// </summary> /// </summary>
/// <param name="name">The name of the option to add.</param> /// <param name="name">The name of the option to add.</param>
/// <param name="type">The type of this option.</param> /// <param name="type">The type of this option.</param>
/// <param name="description">The sescription of this option.</param>
/// <param name="description">The description of this option.</param>
/// <returns>The current builder.</returns> /// <returns>The current builder.</returns>
public SlashCommandBuilder AddOption(string name, ApplicationCommandOptionType type, string description) public SlashCommandBuilder AddOption(string name, ApplicationCommandOptionType type, string description)
=> AddOption(name, type, description, options: null, choices: null); => AddOption(name, type, description, options: null, choices: null);
@@ -294,7 +294,7 @@ namespace Discord


if (value != null) if (value != null)
if (!Regex.IsMatch(value, @"^[\w-]{1,32}$")) if (!Regex.IsMatch(value, @"^[\w-]{1,32}$"))
throw new ArgumentException("Option name cannot contian any special characters or whitespaces!");
throw new ArgumentException("Option name cannot contain any special characters or whitespaces!");


_name = value; _name = value;
} }
@@ -397,7 +397,7 @@ namespace Discord
// Discord updated the docs, this regex prevents special characters like @!$%( and s p a c e s.. etc, // Discord updated the docs, this regex prevents special characters like @!$%( and s p a c e s.. etc,
// https://discord.com/developers/docs/interactions/slash-commands#applicationcommand // https://discord.com/developers/docs/interactions/slash-commands#applicationcommand
if (!Regex.IsMatch(name, @"^[\w-]{1,32}$")) if (!Regex.IsMatch(name, @"^[\w-]{1,32}$"))
throw new ArgumentException("Command name cannot contian any special characters or whitespaces!", nameof(name));
throw new ArgumentException("Command name cannot contain any special characters or whitespaces!", nameof(name));


// same with description // same with description
Preconditions.NotNullOrEmpty(description, nameof(description)); Preconditions.NotNullOrEmpty(description, nameof(description));


+ 1
- 1
src/Discord.Net.Core/Entities/Interactions/Slash Commands/SlashCommandProperties.cs View File

@@ -13,7 +13,7 @@ namespace Discord
{ {
internal override ApplicationCommandType Type => ApplicationCommandType.Slash; internal override ApplicationCommandType Type => ApplicationCommandType.Slash;
/// <summary> /// <summary>
/// The discription of this command.
/// The description of this command.
/// </summary> /// </summary>
public Optional<string> Description { get; set; } public Optional<string> Description { get; set; }




+ 1
- 1
src/Discord.Net.Core/Entities/Messages/IMessage.cs View File

@@ -56,7 +56,7 @@ namespace Discord
/// Gets the clean content for this message. /// Gets the clean content for this message.
/// </summary> /// </summary>
/// <returns> /// <returns>
/// A string that contains the body of the message stripped of mentions, markdown, emojiis and pings; note that this field may be empty if there is an embed.
/// A string that contains the body of the message stripped of mentions, markdown, emojis and pings; note that this field may be empty if there is an embed.
/// </returns> /// </returns>
string CleanContent { get; } string CleanContent { get; }
/// <summary> /// <summary>


+ 1
- 1
src/Discord.Net.Core/Entities/Messages/TimestampTag.cs View File

@@ -27,7 +27,7 @@ namespace Discord
/// If the <see cref="TimestampTag.Time"/> is null then the default 0 will be used. /// If the <see cref="TimestampTag.Time"/> is null then the default 0 will be used.
/// </para> /// </para>
/// </summary> /// </summary>
/// <returns>A string thats compatable in a discord message, ex: <code>&lt;t:1625944201:f&gt;</code></returns>
/// <returns>A string thats compatible in a discord message, ex: <code>&lt;t:1625944201:f&gt;</code></returns>
public override string ToString() public override string ToString()
{ {
if (Time == null) if (Time == null)


+ 2
- 2
src/Discord.Net.Core/Entities/Permissions/ChannelPermissions.cs View File

@@ -85,7 +85,7 @@ namespace Discord
/// <summary> If <c>true</c>, a user may stream video in a voice channel.</summary> /// <summary> If <c>true</c>, a user may stream video in a voice channel.</summary>
public bool Stream => Permissions.GetValue(RawValue, ChannelPermission.Stream); public bool Stream => Permissions.GetValue(RawValue, ChannelPermission.Stream);


/// <summary> If <c>true</c>, a user may adjust role permissions. This also implictly grants all other permissions.</summary>
/// <summary> If <c>true</c>, a user may adjust role permissions. This also implicitly grants all other permissions.</summary>
public bool ManageRoles => Permissions.GetValue(RawValue, ChannelPermission.ManageRoles); public bool ManageRoles => Permissions.GetValue(RawValue, ChannelPermission.ManageRoles);
/// <summary> If <c>true</c>, a user may edit the webhooks for this channel.</summary> /// <summary> If <c>true</c>, a user may edit the webhooks for this channel.</summary>
public bool ManageWebhooks => Permissions.GetValue(RawValue, ChannelPermission.ManageWebhooks); public bool ManageWebhooks => Permissions.GetValue(RawValue, ChannelPermission.ManageWebhooks);
@@ -103,7 +103,7 @@ namespace Discord
public bool UseExternalStickers => Permissions.GetValue(RawValue, ChannelPermission.UseExternalStickers); public bool UseExternalStickers => Permissions.GetValue(RawValue, ChannelPermission.UseExternalStickers);
/// <summary> If <c>true</c>, a user may send messages in threads in this guild.</summary> /// <summary> If <c>true</c>, a user may send messages in threads in this guild.</summary>
public bool SendMessagesInThreads => Permissions.GetValue(RawValue, ChannelPermission.SendMessagesInThreads); public bool SendMessagesInThreads => Permissions.GetValue(RawValue, ChannelPermission.SendMessagesInThreads);
/// <summary> If <c>true</c>, a user launch application activites in voice channels in this guild.</summary>
/// <summary> If <c>true</c>, a user launch application activities in voice channels in this guild.</summary>
public bool StartEmbeddedActivities => Permissions.GetValue(RawValue, ChannelPermission.StartEmbeddedActivities); public bool StartEmbeddedActivities => Permissions.GetValue(RawValue, ChannelPermission.StartEmbeddedActivities);


/// <summary> Creates a new <see cref="ChannelPermissions"/> with the provided packed value.</summary> /// <summary> Creates a new <see cref="ChannelPermissions"/> with the provided packed value.</summary>


+ 1
- 1
src/Discord.Net.Core/Entities/Permissions/GuildPermissions.cs View File

@@ -97,7 +97,7 @@ namespace Discord
public bool UseExternalStickers => Permissions.GetValue(RawValue, GuildPermission.UseExternalStickers); public bool UseExternalStickers => Permissions.GetValue(RawValue, GuildPermission.UseExternalStickers);
/// <summary> If <c>true</c>, a user may send messages in threads in this guild. </summary> /// <summary> If <c>true</c>, a user may send messages in threads in this guild. </summary>
public bool SendMessagesInThreads => Permissions.GetValue(RawValue, GuildPermission.SendMessagesInThreads); public bool SendMessagesInThreads => Permissions.GetValue(RawValue, GuildPermission.SendMessagesInThreads);
/// <summary> If <c>true</c>, a user launch application activites in voice channels in this guild. </summary>
/// <summary> If <c>true</c>, a user launch application activities in voice channels in this guild. </summary>
public bool StartEmbeddedActivities => Permissions.GetValue(RawValue, GuildPermission.StartEmbeddedActivities); public bool StartEmbeddedActivities => Permissions.GetValue(RawValue, GuildPermission.StartEmbeddedActivities);


/// <summary> Creates a new <see cref="GuildPermissions"/> with the provided packed value. </summary> /// <summary> Creates a new <see cref="GuildPermissions"/> with the provided packed value. </summary>


+ 1
- 1
src/Discord.Net.Core/Entities/Permissions/OverwritePermissions.cs View File

@@ -97,7 +97,7 @@ namespace Discord
public PermValue UseExternalStickers => Permissions.GetValue(AllowValue, DenyValue, ChannelPermission.UseExternalStickers); public PermValue UseExternalStickers => Permissions.GetValue(AllowValue, DenyValue, ChannelPermission.UseExternalStickers);
/// <summary> If <c>true</c>, a user may send messages in threads in this guild. </summary> /// <summary> If <c>true</c>, a user may send messages in threads in this guild. </summary>
public PermValue SendMessagesInThreads => Permissions.GetValue(AllowValue, DenyValue, ChannelPermission.SendMessagesInThreads); public PermValue SendMessagesInThreads => Permissions.GetValue(AllowValue, DenyValue, ChannelPermission.SendMessagesInThreads);
/// <summary> If <c>true</c>, a user launch application activites in voice channels in this guild. </summary>
/// <summary> If <c>true</c>, a user launch application activities in voice channels in this guild. </summary>
public PermValue StartEmbeddedActivities => Permissions.GetValue(AllowValue, DenyValue, ChannelPermission.StartEmbeddedActivities); public PermValue StartEmbeddedActivities => Permissions.GetValue(AllowValue, DenyValue, ChannelPermission.StartEmbeddedActivities);


/// <summary> Creates a new OverwritePermissions with the provided allow and deny packed values. </summary> /// <summary> Creates a new OverwritePermissions with the provided allow and deny packed values. </summary>


+ 1
- 1
src/Discord.Net.Core/Entities/Stickers/ICustomSticker.cs View File

@@ -51,7 +51,7 @@ namespace Discord
/// Deletes the current sticker. /// Deletes the current sticker.
/// </summary> /// </summary>
/// <remakrs> /// <remakrs>
/// The bot neeeds the MANAGE_EMOJIS_AND_STICKERS permission inside the guild in order to delete stickers.
/// The bot needs the MANAGE_EMOJIS_AND_STICKERS permission inside the guild in order to delete stickers.
/// </remakrs> /// </remakrs>
/// <param name="options">The options to be used when sending the request.</param> /// <param name="options">The options to be used when sending the request.</param>
/// <returns> /// <returns>


+ 2
- 2
src/Discord.Net.Core/Extensions/MessageExtensions.cs View File

@@ -24,7 +24,7 @@ namespace Discord
/// Add multiple reactions to a message. /// Add multiple reactions to a message.
/// </summary> /// </summary>
/// <remarks> /// <remarks>
/// This method does not bulk add reactions! It will send a request for each reaction inculded.
/// This method does not bulk add reactions! It will send a request for each reaction included.
/// </remarks> /// </remarks>
/// <example> /// <example>
/// <code language="cs"> /// <code language="cs">
@@ -76,7 +76,7 @@ namespace Discord
/// <summary> /// <summary>
/// Sends an inline reply that references a message. /// Sends an inline reply that references a message.
/// </summary> /// </summary>
/// <param name="msg">The message that is being replyed on.</param>
/// <param name="msg">The message that is being replied on.</param>
/// <param name="text">The message to be sent.</param> /// <param name="text">The message to be sent.</param>
/// <param name="isTTS">Determines whether the message should be read aloud by Discord or not.</param> /// <param name="isTTS">Determines whether the message should be read aloud by Discord or not.</param>
/// <param name="embed">The <see cref="Discord.EmbedType.Rich"/> <see cref="Embed"/> to be sent.</param> /// <param name="embed">The <see cref="Discord.EmbedType.Rich"/> <see cref="Embed"/> to be sent.</param>


+ 1
- 1
src/Discord.Net.Core/Format.cs View File

@@ -15,7 +15,7 @@ namespace Discord
public static string Italics(string text) => $"*{text}*"; public static string Italics(string text) => $"*{text}*";
/// <summary> Returns a markdown-formatted string with underline formatting. </summary> /// <summary> Returns a markdown-formatted string with underline formatting. </summary>
public static string Underline(string text) => $"__{text}__"; public static string Underline(string text) => $"__{text}__";
/// <summary> Returns a markdown-formatted string with strikethrough formatting. </summary>
/// <summary> Returns a markdown-formatted string with strike-through formatting. </summary>
public static string Strikethrough(string text) => $"~~{text}~~"; public static string Strikethrough(string text) => $"~~{text}~~";
/// <summary> Returns a string with spoiler formatting. </summary> /// <summary> Returns a string with spoiler formatting. </summary>
public static string Spoiler(string text) => $"||{text}||"; public static string Spoiler(string text) => $"||{text}||";


+ 2
- 2
src/Discord.Net.Core/RequestOptions.cs View File

@@ -16,10 +16,10 @@ namespace Discord
public static RequestOptions Default => new RequestOptions(); public static RequestOptions Default => new RequestOptions();


/// <summary> /// <summary>
/// Gets or sets the maximum time to wait for for this request to complete.
/// Gets or sets the maximum time to wait for this request to complete.
/// </summary> /// </summary>
/// <remarks> /// <remarks>
/// Gets or set the max time, in milliseconds, to wait for for this request to complete. If
/// Gets or set the max time, in milliseconds, to wait for this request to complete. If
/// <c>null</c>, a request will not time out. If a rate limit has been triggered for this request's bucket /// <c>null</c>, a request will not time out. If a rate limit has been triggered for this request's bucket
/// and will not be unpaused in time, this request will fail immediately. /// and will not be unpaused in time, this request will fail immediately.
/// </remarks> /// </remarks>


+ 0
- 1
src/Discord.Net.Examples/Core/Entities/Channels/IMessageChannel.Examples.cs View File

@@ -108,7 +108,6 @@ namespace Discord.Net.Examples.Core.Entities.Channels
using (channel.EnterTypingState()) await LongRunningAsync(); using (channel.EnterTypingState()) await LongRunningAsync();


#endregion #endregion

} }
} }
} }

+ 1
- 1
src/Discord.Net.Rest/DiscordRestApiClient.cs View File

@@ -2227,7 +2227,7 @@ namespace Discord.API
Array.Copy(elements, 0, methodArgs, 1, elements.Length); Array.Copy(elements, 0, methodArgs, 1, elements.Length);
} }


int endIndex = format.IndexOf('?'); //Dont include params
int endIndex = format.IndexOf('?'); //Don't include params
if (endIndex == -1) if (endIndex == -1)
endIndex = format.Length; endIndex = format.Length;




+ 3
- 3
src/Discord.Net.Rest/Entities/Channels/RestThreadChannel.cs View File

@@ -10,7 +10,7 @@ using Model = Discord.API.Channel;
namespace Discord.Rest namespace Discord.Rest
{ {
/// <summary> /// <summary>
/// Represents a thread channel recieved over REST.
/// Represents a thread channel received over REST.
/// </summary> /// </summary>
public class RestThreadChannel : RestTextChannel, IThreadChannel public class RestThreadChannel : RestTextChannel, IThreadChannel
{ {
@@ -81,7 +81,7 @@ namespace Discord.Rest
/// <param name="userId">The id of the user to fetch.</param> /// <param name="userId">The id of the user to fetch.</param>
/// <param name="options">The options to be used when sending the request.</param> /// <param name="options">The options to be used when sending the request.</param>
/// <returns> /// <returns>
/// A task representing the asyncronous get operation. The task returns a
/// A task representing the asynchronous get operation. The task returns a
/// <see cref="RestThreadUser"/> if found, otherwise <see langword="null"/>. /// <see cref="RestThreadUser"/> if found, otherwise <see langword="null"/>.
/// </returns> /// </returns>
public new Task<RestThreadUser> GetUserAsync(ulong userId, RequestOptions options = null) public new Task<RestThreadUser> GetUserAsync(ulong userId, RequestOptions options = null)
@@ -92,7 +92,7 @@ namespace Discord.Rest
/// </summary> /// </summary>
/// <param name="options">The options to be used when sending the request.</param> /// <param name="options">The options to be used when sending the request.</param>
/// <returns> /// <returns>
/// A task representing the asyncronous get operation. The task returns a
/// A task representing the asynchronous get operation. The task returns a
/// <see cref="IReadOnlyCollection{T}"/> of <see cref="RestThreadUser"/>'s. /// <see cref="IReadOnlyCollection{T}"/> of <see cref="RestThreadUser"/>'s.
/// </returns> /// </returns>
public new async Task<IReadOnlyCollection<RestThreadUser>> GetUsersAsync(RequestOptions options = null) public new async Task<IReadOnlyCollection<RestThreadUser>> GetUsersAsync(RequestOptions options = null)


+ 4
- 4
src/Discord.Net.Rest/Entities/Guilds/RestGuild.cs View File

@@ -578,7 +578,7 @@ namespace Discord.Rest
/// <param name="options">The options to be used when sending the request.</param> /// <param name="options">The options to be used when sending the request.</param>
/// <returns> /// <returns>
/// A task that represents the asynchronous get operation. The task result contains the text channel /// A task that represents the asynchronous get operation. The task result contains the text channel
/// where guild notices such as welcome messages and boost events are poste; <see langword="null"/> if none is found.
/// where guild notices such as welcome messages and boost events are post; <see langword="null"/> if none is found.
/// </returns> /// </returns>
public async Task<RestTextChannel> GetSystemChannelAsync(RequestOptions options = null) public async Task<RestTextChannel> GetSystemChannelAsync(RequestOptions options = null)
{ {
@@ -611,11 +611,11 @@ namespace Discord.Rest
} }


/// <summary> /// <summary>
/// Gets the text channel channel where admins and moderators of Community guilds receive notices from Discord.
/// Gets the text channel where admins and moderators of Community guilds receive notices from Discord.
/// </summary> /// </summary>
/// <param name="options">The options to be used when sending the request.</param> /// <param name="options">The options to be used when sending the request.</param>
/// <returns> /// <returns>
/// A task that represents the asynchronous get operation. The task result contains the text channel channel where
/// A task that represents the asynchronous get operation. The task result contains the text channel where
/// admins and moderators of Community guilds receive notices from Discord; <see langword="null"/> if none is set. /// admins and moderators of Community guilds receive notices from Discord; <see langword="null"/> if none is set.
/// </returns> /// </returns>
public async Task<RestTextChannel> GetPublicUpdatesChannelAsync(RequestOptions options = null) public async Task<RestTextChannel> GetPublicUpdatesChannelAsync(RequestOptions options = null)
@@ -914,7 +914,7 @@ namespace Discord.Rest


#region Interactions #region Interactions
/// <summary> /// <summary>
/// Gets this guilds slash commands commands
/// Gets this guilds slash commands
/// </summary> /// </summary>
/// <param name="options">The options to be used when sending the request.</param> /// <param name="options">The options to be used when sending the request.</param>
/// <returns> /// <returns>


+ 0
- 1
src/Discord.Net.Rest/Entities/Interactions/InteractionHelper.cs View File

@@ -1,7 +1,6 @@
using Discord.API; using Discord.API;
using Discord.API.Rest; using Discord.API.Rest;
using Discord.Net; using Discord.Net;
//using Discord.Rest.Entities.Interactions;
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.Linq; using System.Linq;


+ 1
- 1
src/Discord.Net.Rest/Entities/Messages/CustomSticker.cs View File

@@ -26,7 +26,7 @@ namespace Discord.Rest
/// Gets the guild that this custom sticker is in. /// Gets the guild that this custom sticker is in.
/// </summary> /// </summary>
/// <remarks> /// <remarks>
/// <b>Note</b>: This property can be <see langword="null"/> if the sticker wasnt fetched from a guild.
/// <b>Note</b>: This property can be <see langword="null"/> if the sticker wasn't fetched from a guild.
/// </remarks> /// </remarks>
public RestGuild Guild { get; private set; } public RestGuild Guild { get; private set; }




+ 2
- 2
src/Discord.Net.Rest/Entities/Messages/RestFollowupMessage.cs View File

@@ -35,7 +35,7 @@ namespace Discord.Rest
} }


/// <summary> /// <summary>
/// Deletes this object and all of it's childern.
/// Deletes this object and all of it's children.
/// </summary> /// </summary>
/// <returns>A task that represents the asynchronous delete operation.</returns> /// <returns>A task that represents the asynchronous delete operation.</returns>
public Task DeleteAsync() public Task DeleteAsync()
@@ -60,7 +60,7 @@ namespace Discord.Rest
/// A task that represents the asynchronous modification operation. /// A task that represents the asynchronous modification operation.
/// </returns> /// </returns>
/// <exception cref="InvalidOperationException">The token used to modify/delete this message expired.</exception> /// <exception cref="InvalidOperationException">The token used to modify/delete this message expired.</exception>
/// /// <exception cref="Discord.Net.HttpException">Somthing went wrong during the request.</exception>
/// /// <exception cref="Discord.Net.HttpException">Something went wrong during the request.</exception>
public new async Task ModifyAsync(Action<MessageProperties> func, RequestOptions options = null) public new async Task ModifyAsync(Action<MessageProperties> func, RequestOptions options = null)
{ {
try try


+ 2
- 2
src/Discord.Net.Rest/Entities/Messages/RestInteractionMessage.cs View File

@@ -31,7 +31,7 @@ namespace Discord.Rest
} }


/// <summary> /// <summary>
/// Deletes this object and all of it's childern.
/// Deletes this object and all of it's children.
/// </summary> /// </summary>
/// <returns>A task that represents the asynchronous delete operation.</returns> /// <returns>A task that represents the asynchronous delete operation.</returns>
public Task DeleteAsync() public Task DeleteAsync()
@@ -56,7 +56,7 @@ namespace Discord.Rest
/// A task that represents the asynchronous modification operation. /// A task that represents the asynchronous modification operation.
/// </returns> /// </returns>
/// <exception cref="InvalidOperationException">The token used to modify/delete this message expired.</exception> /// <exception cref="InvalidOperationException">The token used to modify/delete this message expired.</exception>
/// /// <exception cref="Discord.Net.HttpException">Somthing went wrong during the request.</exception>
/// /// <exception cref="Discord.Net.HttpException">Something went wrong during the request.</exception>
public new async Task ModifyAsync(Action<MessageProperties> func, RequestOptions options = null) public new async Task ModifyAsync(Action<MessageProperties> func, RequestOptions options = null)
{ {
try try


+ 0
- 1
src/Discord.Net.Rest/Entities/Webhooks/WebhookHelper.cs View File

@@ -33,6 +33,5 @@ namespace Discord.Rest
{ {
await client.ApiClient.DeleteWebhookAsync(webhook.Id, options).ConfigureAwait(false); await client.ApiClient.DeleteWebhookAsync(webhook.Id, options).ConfigureAwait(false);
} }

} }
} }

+ 2
- 2
src/Discord.Net.Rest/Net/Queue/RequestQueueBucket.cs View File

@@ -435,7 +435,7 @@ namespace Discord.Net.Queue
if (!hasQueuedReset || resetTick > _resetTick) if (!hasQueuedReset || resetTick > _resetTick)
{ {
_resetTick = resetTick; _resetTick = resetTick;
LastAttemptAt = resetTick.Value; //Make sure we dont destroy this until after its been reset
LastAttemptAt = resetTick.Value; //Make sure we don't destroy this until after its been reset
#if DEBUG_LIMITS #if DEBUG_LIMITS
Debug.WriteLine($"[{id}] Reset in {(int)Math.Ceiling((resetTick - DateTimeOffset.UtcNow).Value.TotalMilliseconds)} ms"); Debug.WriteLine($"[{id}] Reset in {(int)Math.Ceiling((resetTick - DateTimeOffset.UtcNow).Value.TotalMilliseconds)} ms");
#endif #endif
@@ -456,7 +456,7 @@ namespace Discord.Net.Queue
lock (_lock) lock (_lock)
{ {
millis = (int)Math.Ceiling((_resetTick.Value - DateTimeOffset.UtcNow).TotalMilliseconds); millis = (int)Math.Ceiling((_resetTick.Value - DateTimeOffset.UtcNow).TotalMilliseconds);
if (millis <= 0) //Make sure we havent gotten a more accurate reset time
if (millis <= 0) //Make sure we haven't gotten a more accurate reset time
{ {
#if DEBUG_LIMITS #if DEBUG_LIMITS
Debug.WriteLine($"[{id}] * Reset *"); Debug.WriteLine($"[{id}] * Reset *");


+ 1
- 1
src/Discord.Net.WebSocket/API/Voice/ReadyEvent.cs View File

@@ -14,7 +14,7 @@ namespace Discord.API.Voice
[JsonProperty("modes")] [JsonProperty("modes")]
public string[] Modes { get; set; } public string[] Modes { get; set; }
[JsonProperty("heartbeat_interval")] [JsonProperty("heartbeat_interval")]
[Obsolete("This field is errorneous and should not be used", true)]
[Obsolete("This field is erroneous and should not be used", true)]
public int HeartbeatInterval { get; set; } public int HeartbeatInterval { get; set; }
} }
} }

+ 1
- 1
src/Discord.Net.WebSocket/Audio/Streams/BufferedWriteStream.cs View File

@@ -125,7 +125,7 @@ namespace Discord.Audio.Streams
timestamp += OpusEncoder.FrameSamplesPerChannel; timestamp += OpusEncoder.FrameSamplesPerChannel;
} }
#if DEBUG #if DEBUG
var _ = _logger?.DebugAsync("Buffer underrun");
var _ = _logger?.DebugAsync("Buffer under run");
#endif #endif
} }
} }


+ 3
- 3
src/Discord.Net.WebSocket/DiscordSocketClient.cs View File

@@ -51,7 +51,7 @@ namespace Discord.WebSocket
/// Provides access to a REST-only client with a shared state from this client. /// Provides access to a REST-only client with a shared state from this client.
/// </summary> /// </summary>
public override DiscordSocketRestClient Rest { get; } public override DiscordSocketRestClient Rest { get; }
/// <summary> Gets the shard of of this client. </summary>
/// <summary> Gets the shard of this client. </summary>
public int ShardId { get; } public int ShardId { get; }
/// <summary> Gets the current connection state of this client. </summary> /// <summary> Gets the current connection state of this client. </summary>
public ConnectionState ConnectionState => _connection.State; public ConnectionState ConnectionState => _connection.State;
@@ -438,7 +438,7 @@ namespace Discord.WebSocket


var entity = State.GetOrAddCommand(model.Id, (id) => SocketApplicationCommand.Create(this, model)); var entity = State.GetOrAddCommand(model.Id, (id) => SocketApplicationCommand.Create(this, model));


//Update it incase it was cached
//Update it in case it was cached
entity.Update(model); entity.Update(model);


return entity; return entity;
@@ -1522,7 +1522,7 @@ namespace Discord.WebSocket
} }
else else
{ {
//Edited message isnt in cache, create a detached one
//Edited message isn't in cache, create a detached one
SocketUser author; SocketUser author;
if (data.Author.IsSpecified) if (data.Author.IsSpecified)
{ {


+ 1
- 1
src/Discord.Net.WebSocket/DiscordSocketConfig.cs View File

@@ -79,7 +79,7 @@ namespace Discord.WebSocket
/// <remarks> /// <remarks>
/// <para> /// <para>
/// By default, the Discord gateway will only send offline members if a guild has less than a certain number /// By default, the Discord gateway will only send offline members if a guild has less than a certain number
/// of members (determined by <see cref="LargeThreshold"/> in this library). This behaviour is why
/// of members (determined by <see cref="LargeThreshold"/> in this library). This behavior is why
/// sometimes a user may be missing from the WebSocket cache for collections such as /// sometimes a user may be missing from the WebSocket cache for collections such as
/// <see cref="Discord.WebSocket.SocketGuild.Users"/>. /// <see cref="Discord.WebSocket.SocketGuild.Users"/>.
/// </para> /// </para>


+ 1
- 1
src/Discord.Net.WebSocket/Entities/Channels/SocketStageChannel.cs View File

@@ -11,7 +11,7 @@ using StageInstance = Discord.API.StageInstance;
namespace Discord.WebSocket namespace Discord.WebSocket
{ {
/// <summary> /// <summary>
/// Represents a stage channel recieved over the gateway.
/// Represents a stage channel received over the gateway.
/// </summary> /// </summary>
public class SocketStageChannel : SocketVoiceChannel, IStageChannel public class SocketStageChannel : SocketVoiceChannel, IStageChannel
{ {


+ 1
- 1
src/Discord.Net.WebSocket/Entities/Guilds/SocketGuild.cs View File

@@ -1551,7 +1551,7 @@ namespace Discord.WebSocket
} }
internal async Task FinishConnectAudio(string url, string token) internal async Task FinishConnectAudio(string url, string token)
{ {
//TODO: Mem Leak: Disconnected/Connected handlers arent cleaned up
//TODO: Mem Leak: Disconnected/Connected handlers aren't cleaned up
var voiceState = GetVoiceState(Discord.CurrentUser.Id).Value; var voiceState = GetVoiceState(Discord.CurrentUser.Id).Value;


await _audioLock.WaitAsync().ConfigureAwait(false); await _audioLock.WaitAsync().ConfigureAwait(false);


+ 1
- 1
src/Discord.Net.WebSocket/Entities/Interaction/Context Menu Commands/Message Commands/SocketMessageCommandData.cs View File

@@ -10,7 +10,7 @@ namespace Discord.WebSocket
public class SocketMessageCommandData : SocketCommandBaseData public class SocketMessageCommandData : SocketCommandBaseData
{ {
/// <summary> /// <summary>
/// Gets the messagte associated with this message command.
/// Gets the message associated with this message command.
/// </summary> /// </summary>
public SocketMessage Message public SocketMessage Message
=> ResolvableData?.Messages.FirstOrDefault().Value; => ResolvableData?.Messages.FirstOrDefault().Value;


+ 2
- 2
src/Discord.Net.WebSocket/Entities/Interaction/Message Components/SocketMessageComponent.cs View File

@@ -131,7 +131,7 @@ namespace Discord.WebSocket
/// Updates the message which this component resides in with the type <see cref="InteractionResponseType.UpdateMessage"/> /// Updates the message which this component resides in with the type <see cref="InteractionResponseType.UpdateMessage"/>
/// </summary> /// </summary>
/// <param name="func">A delegate containing the properties to modify the message with.</param> /// <param name="func">A delegate containing the properties to modify the message with.</param>
/// <param name="options">The request options for this async request.</param>
/// <param name="options">The request options for this <see langword="async"/> request.</param>
/// <returns>A task that represents the asynchronous operation of updating the message.</returns> /// <returns>A task that represents the asynchronous operation of updating the message.</returns>
public async Task UpdateAsync(Action<MessageProperties> func, RequestOptions options = null) public async Task UpdateAsync(Action<MessageProperties> func, RequestOptions options = null)
{ {
@@ -330,7 +330,7 @@ namespace Discord.WebSocket
/// Defers an interaction and responds with type 5 (<see cref="InteractionResponseType.DeferredChannelMessageWithSource"/>) /// Defers an interaction and responds with type 5 (<see cref="InteractionResponseType.DeferredChannelMessageWithSource"/>)
/// </summary> /// </summary>
/// <param name="ephemeral"><see langword="true"/> to send this message ephemerally, otherwise <see langword="false"/>.</param> /// <param name="ephemeral"><see langword="true"/> to send this message ephemerally, otherwise <see langword="false"/>.</param>
/// <param name="options">The request options for this async request.</param>
/// <param name="options">The request options for this <see langword="async"/> request.</param>
/// <returns> /// <returns>
/// A task that represents the asynchronous operation of acknowledging the interaction. /// A task that represents the asynchronous operation of acknowledging the interaction.
/// </returns> /// </returns>


+ 1
- 1
src/Discord.Net.WebSocket/Entities/Interaction/Slash Commands/SocketAutocompleteInteraction.cs View File

@@ -75,7 +75,7 @@ namespace Discord.WebSocket




/// <inheritdoc/> /// <inheritdoc/>
[Obsolete("Autocomplete interactions cannot be defered!", true)]
[Obsolete("Autocomplete interactions cannot be deferred!", true)]
public override Task DeferAsync(bool ephemeral = false, RequestOptions options = null) => throw new NotSupportedException(); public override Task DeferAsync(bool ephemeral = false, RequestOptions options = null) => throw new NotSupportedException();


/// <inheritdoc/> /// <inheritdoc/>


+ 1
- 1
src/Discord.Net.WebSocket/Entities/Interaction/Slash Commands/SocketAutocompleteInteractionData.cs View File

@@ -35,7 +35,7 @@ namespace Discord.WebSocket
public ulong Version { get; } public ulong Version { get; }


/// <summary> /// <summary>
/// Gets the current autocomplete option that is activly being filled out.
/// Gets the current autocomplete option that is actively being filled out.
/// </summary> /// </summary>
public AutocompleteOption Current { get; } public AutocompleteOption Current { get; }




+ 1
- 1
src/Discord.Net.WebSocket/Entities/Interaction/Slash Commands/SocketSlashCommandDataOption.cs View File

@@ -6,7 +6,7 @@ using Model = Discord.API.ApplicationCommandInteractionDataOption;
namespace Discord.WebSocket namespace Discord.WebSocket
{ {
/// <summary> /// <summary>
/// Represents a Websocket-based <see cref="IApplicationCommandInteractionDataOption"/> recieved by the gateway
/// Represents a Websocket-based <see cref="IApplicationCommandInteractionDataOption"/> received by the gateway
/// </summary> /// </summary>
public class SocketSlashCommandDataOption : IApplicationCommandInteractionDataOption public class SocketSlashCommandDataOption : IApplicationCommandInteractionDataOption
{ {


+ 1
- 1
src/Discord.Net.WebSocket/Entities/Interaction/SocketInteraction.cs View File

@@ -8,7 +8,7 @@ using System.IO;
namespace Discord.WebSocket namespace Discord.WebSocket
{ {
/// <summary> /// <summary>
/// Represents an Interaction recieved over the gateway.
/// Represents an Interaction received over the gateway.
/// </summary> /// </summary>
public abstract class SocketInteraction : SocketEntity<ulong>, IDiscordInteraction public abstract class SocketInteraction : SocketEntity<ulong>, IDiscordInteraction
{ {


+ 1
- 1
src/Discord.Net.WebSocket/Entities/Stickers/SocketCustomSticker.cs View File

@@ -23,7 +23,7 @@ namespace Discord.WebSocket
/// <remarks> /// <remarks>
/// <note> /// <note>
/// This may return <see langword="null"/> in the WebSocket implementation due to incomplete user collection in /// This may return <see langword="null"/> in the WebSocket implementation due to incomplete user collection in
/// large guilds, or the bot doesnt have the MANAGE_EMOJIS_AND_STICKERS permission.
/// large guilds, or the bot doesn't have the MANAGE_EMOJIS_AND_STICKERS permission.
/// </note> /// </note>
/// </remarks> /// </remarks>
public SocketGuildUser Author public SocketGuildUser Author


+ 1
- 1
test/Discord.Net.Tests.Unit/EmbedBuilderTests.cs View File

@@ -171,7 +171,7 @@ namespace Discord
} }


/// <summary> /// <summary>
/// Tests that valid urls do not throw any exceptions.
/// Tests that valid url's do not throw any exceptions.
/// </summary> /// </summary>
/// <param name="url">The url to set.</param> /// <param name="url">The url to set.</param>
[Theory] [Theory]


+ 1
- 1
test/Discord.Net.Tests.Unit/FormatTests.cs View File

@@ -68,7 +68,7 @@ namespace Discord
[InlineData(">>__uwu__", "uwu")] [InlineData(">>__uwu__", "uwu")]
[InlineData("```uwu```", "uwu")] [InlineData("```uwu```", "uwu")]
[InlineData("~uwu~", "uwu")] [InlineData("~uwu~", "uwu")]
[InlineData("berries __and__ *Cream**, i'm a little lad who loves berries and cream", "berries and Cream, i'm a little lad who loves berries and cream")]
[InlineData("berries __and__ *Cream**, I'm a little lad who loves berries and cream", "berries and Cream, I'm a little lad who loves berries and cream")]
public void StripMarkdown(string input, string expected) public void StripMarkdown(string input, string expected)
{ {
var test = Format.StripMarkDown(input); var test = Format.StripMarkDown(input);


Loading…
Cancel
Save