Fix typos in comments and documentation (#2608)
* Fix typos in comments and documentations * Fixes more typo
This commit is contained in:
@@ -9,12 +9,12 @@ namespace Discord
|
||||
/// </summary>
|
||||
public class DiscordConfig
|
||||
{
|
||||
/// <summary>
|
||||
/// Returns the API version Discord.Net uses.
|
||||
/// <summary>
|
||||
/// Returns the API version Discord.Net uses.
|
||||
/// </summary>
|
||||
/// <returns>
|
||||
/// An <see cref="int"/> representing the API version that Discord.Net uses to communicate with Discord.
|
||||
/// <para>A list of available API version can be seen on the official
|
||||
/// <para>A list of available API version can be seen on the official
|
||||
/// <see href="https://discord.com/developers/docs/reference#api-versioning">Discord API documentation</see>
|
||||
/// .</para>
|
||||
/// </returns>
|
||||
@@ -53,14 +53,14 @@ namespace Discord
|
||||
/// The Discord API URL using <see cref="APIVersion"/>.
|
||||
/// </returns>
|
||||
public static readonly string APIUrl = $"https://discord.com/api/v{APIVersion}/";
|
||||
/// <summary>
|
||||
/// Returns the base Discord CDN URL.
|
||||
/// <summary>
|
||||
/// Returns the base Discord CDN URL.
|
||||
/// </summary>
|
||||
/// <returns>
|
||||
/// The base Discord Content Delivery Network (CDN) URL.
|
||||
/// </returns>
|
||||
public const string CDNUrl = "https://cdn.discordapp.com/";
|
||||
/// <summary>
|
||||
/// <summary>
|
||||
/// Returns the base Discord invite URL.
|
||||
/// </summary>
|
||||
/// <returns>
|
||||
@@ -68,28 +68,28 @@ namespace Discord
|
||||
/// </returns>
|
||||
public const string InviteUrl = "https://discord.gg/";
|
||||
|
||||
/// <summary>
|
||||
/// Returns the default timeout for requests.
|
||||
/// <summary>
|
||||
/// Returns the default timeout for requests.
|
||||
/// </summary>
|
||||
/// <returns>
|
||||
/// The amount of time it takes in milliseconds before a request is timed out.
|
||||
/// </returns>
|
||||
public const int DefaultRequestTimeout = 15000;
|
||||
/// <summary>
|
||||
/// Returns the max length for a Discord message.
|
||||
/// <summary>
|
||||
/// Returns the max length for a Discord message.
|
||||
/// </summary>
|
||||
/// <returns>
|
||||
/// The maximum length of a message allowed by Discord.
|
||||
/// </returns>
|
||||
public const int MaxMessageSize = 2000;
|
||||
/// <summary>
|
||||
/// Returns the max messages allowed to be in a request.
|
||||
/// <summary>
|
||||
/// Returns the max messages allowed to be in a request.
|
||||
/// </summary>
|
||||
/// <returns>
|
||||
/// The maximum number of messages that can be gotten per-batch.
|
||||
/// </returns>
|
||||
public const int MaxMessagesPerBatch = 100;
|
||||
/// <summary>
|
||||
/// <summary>
|
||||
/// Returns the max users allowed to be in a request.
|
||||
/// </summary>
|
||||
/// <returns>
|
||||
@@ -110,8 +110,8 @@ namespace Discord
|
||||
/// The maximum number of users that can be gotten per-batch.
|
||||
/// </returns>
|
||||
public const int MaxGuildEventUsersPerBatch = 100;
|
||||
/// <summary>
|
||||
/// Returns the max guilds allowed to be in a request.
|
||||
/// <summary>
|
||||
/// Returns the max guilds allowed to be in a request.
|
||||
/// </summary>
|
||||
/// <returns>
|
||||
/// The maximum number of guilds that can be gotten per-batch.
|
||||
@@ -124,8 +124,8 @@ namespace Discord
|
||||
/// The maximum number of user reactions that can be gotten per-batch.
|
||||
/// </returns>
|
||||
public const int MaxUserReactionsPerBatch = 100;
|
||||
/// <summary>
|
||||
/// Returns the max audit log entries allowed to be in a request.
|
||||
/// <summary>
|
||||
/// Returns the max audit log entries allowed to be in a request.
|
||||
/// </summary>
|
||||
/// <returns>
|
||||
/// The maximum number of audit log entries that can be gotten per-batch.
|
||||
@@ -194,7 +194,7 @@ namespace Discord
|
||||
public bool UseSystemClock { get; set; } = true;
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets whether or not the internal experation check uses the system date
|
||||
/// Gets or sets whether or not the internal expiration check uses the system date
|
||||
/// + snowflake date to check if an interaction can be responded to.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
@@ -215,8 +215,8 @@ namespace Discord
|
||||
/// </remarks>
|
||||
public bool FormatUsersInBidirectionalUnicode { get; set; } = true;
|
||||
|
||||
/// <summary>
|
||||
/// Returns the max thread members allowed to be in a request.
|
||||
/// <summary>
|
||||
/// Returns the max thread members allowed to be in a request.
|
||||
/// </summary>
|
||||
/// <returns>
|
||||
/// The maximum number of thread members that can be gotten per-batch.
|
||||
|
||||
@@ -5,7 +5,7 @@ namespace Discord
|
||||
/// <summary> No messages will be scanned. </summary>
|
||||
Disabled = 0,
|
||||
/// <summary> Scans messages from all guild members that do not have a role. </summary>
|
||||
/// <remarks> Recommented option for servers that use roles for trusted membership. </remarks>
|
||||
/// <remarks> Recommended option for servers that use roles for trusted membership. </remarks>
|
||||
MembersWithoutRoles = 1,
|
||||
/// <summary> Scan messages sent by all guild members. </summary>
|
||||
AllMembers = 2
|
||||
|
||||
@@ -35,7 +35,7 @@ namespace Discord
|
||||
/// Gets the description of the event.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// This field is <see langword="null"/> when the event doesn't have a discription.
|
||||
/// This field is <see langword="null"/> when the event doesn't have a description.
|
||||
/// </remarks>
|
||||
string Description { get; }
|
||||
|
||||
@@ -71,7 +71,7 @@ namespace Discord
|
||||
|
||||
/// <summary>
|
||||
/// Gets the optional entity id of the event. The "entity" of the event
|
||||
/// can be a stage instance event as is seperate from <see cref="ChannelId"/>.
|
||||
/// can be a stage instance event as is separate from <see cref="ChannelId"/>.
|
||||
/// </summary>
|
||||
ulong? EntityId { get; }
|
||||
|
||||
@@ -102,7 +102,7 @@ namespace Discord
|
||||
/// </returns>
|
||||
Task StartAsync(RequestOptions options = null);
|
||||
/// <summary>
|
||||
/// Ends or canceles the event.
|
||||
/// Ends or cancels the event.
|
||||
/// </summary>
|
||||
/// <param name="options">The options to be used when sending the request.</param>
|
||||
/// <returns>
|
||||
@@ -134,7 +134,7 @@ namespace Discord
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <note type="important">
|
||||
/// The returned collection is an asynchronous enumerable object; one must call
|
||||
/// The returned collection is an asynchronous enumerable object; one must call
|
||||
/// <see cref="AsyncEnumerableExtensions.FlattenAsync{T}"/> to access the individual messages as a
|
||||
/// collection.
|
||||
/// </note>
|
||||
@@ -155,7 +155,7 @@ namespace Discord
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <note type="important">
|
||||
/// The returned collection is an asynchronous enumerable object; one must call
|
||||
/// The returned collection is an asynchronous enumerable object; one must call
|
||||
/// <see cref="AsyncEnumerableExtensions.FlattenAsync{T}"/> to access the individual users as a
|
||||
/// collection.
|
||||
/// </note>
|
||||
@@ -165,7 +165,7 @@ namespace Discord
|
||||
/// </note>
|
||||
/// This method will attempt to fetch the number of users specified under <paramref name="limit"/> around
|
||||
/// the user <paramref name="fromUserId"/> depending on the <paramref name="dir"/>. The library will
|
||||
/// attempt to split up the requests according to your <paramref name="limit"/> and
|
||||
/// attempt to split up the requests according to your <paramref name="limit"/> and
|
||||
/// <see cref="DiscordConfig.MaxGuildEventUsersPerBatch"/>. In other words, should the user request 500 users,
|
||||
/// and the <see cref="Discord.DiscordConfig.MaxGuildEventUsersPerBatch"/> constant is <c>100</c>, the request will
|
||||
/// be split into 5 individual requests; thus returning 5 individual asynchronous responses, hence the need
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
namespace Discord
|
||||
{
|
||||
/// <summary>
|
||||
/// Respresents a <see cref="IMessageComponent"/> text input.
|
||||
/// Represents a <see cref="IMessageComponent"/> text input.
|
||||
/// </summary>
|
||||
public class TextInputComponent : IMessageComponent
|
||||
{
|
||||
@@ -17,7 +17,7 @@ namespace Discord
|
||||
public string Label { get; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets the placeholder of the component.
|
||||
/// Gets the placeholder of the component.
|
||||
/// </summary>
|
||||
public string Placeholder { get; }
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@ namespace Discord
|
||||
internal override ApplicationCommandType Type => ApplicationCommandType.Slash;
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the discription of this command.
|
||||
/// Gets or sets the description of this command.
|
||||
/// </summary>
|
||||
public Optional<string> Description { get; set; }
|
||||
|
||||
|
||||
@@ -161,11 +161,11 @@ namespace Discord
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Tries to parse a string into an <see cref="EmbedBuilder"/>.
|
||||
/// Tries to parse a string into an <see cref="EmbedBuilder"/>.
|
||||
/// </summary>
|
||||
/// <param name="json">The json string to parse.</param>
|
||||
/// <param name="builder">The <see cref="EmbedBuilder"/> with populated values. An empty instance if method returns <see langword="false"/>.</param>
|
||||
/// <returns><see langword="true"/> if <paramref name="json"/> was succesfully parsed. <see langword="false"/> if not.</returns>
|
||||
/// <returns><see langword="true"/> if <paramref name="json"/> was successfully parsed. <see langword="false"/> if not.</returns>
|
||||
public static bool TryParse(string json, out EmbedBuilder builder)
|
||||
{
|
||||
builder = new EmbedBuilder();
|
||||
|
||||
@@ -99,7 +99,7 @@ namespace Discord
|
||||
/// <param name="guildId">Id of the target guild.</param>
|
||||
/// <param name="allow">The value of this permission.</param>
|
||||
/// <returns>
|
||||
/// Instance of <see cref="ApplicationCommandPermission"/> targeting everychannel in a guild.
|
||||
/// Instance of <see cref="ApplicationCommandPermission"/> targeting every channel in a guild.
|
||||
/// </returns>
|
||||
public static ApplicationCommandPermission ForAllChannels(ulong guildId, bool allow) =>
|
||||
new(guildId - 1, ApplicationCommandPermissionTarget.Channel, allow);
|
||||
@@ -110,7 +110,7 @@ namespace Discord
|
||||
/// <param name="guild">Target guild.</param>
|
||||
/// <param name="allow">The value of this permission.</param>
|
||||
/// <returns>
|
||||
/// Instance of <see cref="ApplicationCommandPermission"/> targeting everychannel in a guild.
|
||||
/// Instance of <see cref="ApplicationCommandPermission"/> targeting every channel in a guild.
|
||||
/// </returns>
|
||||
public static ApplicationCommandPermission ForAllChannels(IGuild guild, bool allow) =>
|
||||
ForAllChannels(guild.Id, allow);
|
||||
|
||||
@@ -33,7 +33,7 @@ namespace Discord
|
||||
/// </returns>
|
||||
bool? IsRevoked { get; }
|
||||
/// <summary>
|
||||
/// Gets a <see cref="IReadOnlyCollection{T}"/> of integration parials.
|
||||
/// Gets a <see cref="IReadOnlyCollection{T}"/> of integration partials.
|
||||
/// </summary>
|
||||
IReadOnlyCollection<IIntegration> Integrations { get; }
|
||||
/// <summary>
|
||||
|
||||
@@ -111,7 +111,7 @@ namespace Discord
|
||||
/// Formats a user's username + discriminator.
|
||||
/// </summary>
|
||||
/// <param name="doBidirectional">To format the string in bidirectional unicode or not</param>
|
||||
/// <param name="user">The user whos username and discriminator to format</param>
|
||||
/// <param name="user">The user whose username and discriminator to format</param>
|
||||
/// <returns>The username + discriminator</returns>
|
||||
public static string UsernameAndDiscriminator(IUser user, bool doBidirectional)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user