Browse Source

Escape example captions

pull/1484/head
Still Hsu 5 years ago
parent
commit
7ba47a3417
No known key found for this signature in database GPG Key ID: C176DD7907FF62A7
8 changed files with 19 additions and 19 deletions
  1. +4
    -4
      src/Discord.Net.Core/Entities/Channels/INestedChannel.cs
  2. +1
    -1
      src/Discord.Net.Core/Entities/Channels/ITextChannel.cs
  3. +1
    -1
      src/Discord.Net.Core/Entities/Guilds/IGuild.cs
  4. +4
    -4
      src/Discord.Net.Core/Entities/Messages/IMessage.cs
  5. +1
    -1
      src/Discord.Net.Core/Entities/Messages/IUserMessage.cs
  6. +2
    -2
      src/Discord.Net.Core/Entities/Users/IGuildUser.cs
  7. +4
    -4
      src/Discord.Net.Core/Entities/Users/IUser.cs
  8. +2
    -2
      src/Discord.Net.Core/Extensions/UserExtensions.cs

+ 4
- 4
src/Discord.Net.Core/Entities/Channels/INestedChannel.cs View File

@@ -40,8 +40,8 @@ namespace Discord
/// Creates a new invite to this channel.
/// </summary>
/// <example>
/// The following example creates a new invite to this channel; the invite lasts for 12 hours and can only
/// be used 3 times throughout its lifespan.
/// <para>The following example creates a new invite to this channel; the invite lasts for 12 hours and can only
/// be used 3 times throughout its lifespan.</para>
/// <code language="cs">
/// await guildChannel.CreateInviteAsync(maxAge: 43200, maxUses: 3);
/// </code>
@@ -60,8 +60,8 @@ namespace Discord
/// Gets a collection of all invites to this channel.
/// </summary>B
/// <example>
/// The following example gets all of the invites that have been created in this channel and selects the
/// most used invite.
/// <para>The following example gets all of the invites that have been created in this channel and selects the
/// most used invite.</para>
/// <code language="cs">
/// var invites = await channel.GetInvitesAsync();
/// if (invites.Count == 0) return;


+ 1
- 1
src/Discord.Net.Core/Entities/Channels/ITextChannel.cs View File

@@ -39,7 +39,7 @@ namespace Discord
/// Bulk-deletes multiple messages.
/// </summary>
/// <example>
/// The following example gets 250 messages from the channel and deletes them.
/// <para>The following example gets 250 messages from the channel and deletes them.</para>
/// <code language="cs">
/// var messages = await textChannel.GetMessagesAsync(250).FlattenAsync();
/// await textChannel.DeleteMessagesAsync(messages);


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

@@ -510,7 +510,7 @@ namespace Discord
/// Creates a new text channel in this guild.
/// </summary>
/// <example>
/// The following example creates a new text channel under an existing category named <c>Wumpus</c> with a set topic.
/// <para>The following example creates a new text channel under an existing category named <c>Wumpus</c> with a set topic.</para>
/// <code language="cs" region="CreateTextChannelAsync"
/// source="..\..\..\Discord.Net.Examples\Core\Entities\Guilds\IGuild.Examples.cs"/>
/// </example>


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

@@ -161,7 +161,7 @@ namespace Discord
/// Adds a reaction to this message.
/// </summary>
/// <example>
/// The following example adds the reaction, <c>💕</c>, to the message.
/// <para>The following example adds the reaction, <c>💕</c>, to the message.</para>
/// <code language="cs">
/// await msg.AddReactionAsync(new Emoji("\U0001f495"));
/// </code>
@@ -177,7 +177,7 @@ namespace Discord
/// Removes a reaction from message.
/// </summary>
/// <example>
/// The following example removes the reaction, <c>💕</c>, added by the message author from the message.
/// <para>The following example removes the reaction, <c>💕</c>, added by the message author from the message.</para>
/// <code language="cs">
/// await msg.RemoveReactionAsync(new Emoji("\U0001f495"), msg.Author);
/// </code>
@@ -194,7 +194,7 @@ namespace Discord
/// Removes a reaction from message.
/// </summary>
/// <example>
/// The following example removes the reaction, <c>💕</c>, added by the user with ID 84291986575613952 from the message.
/// <para>The following example removes the reaction, <c>💕</c>, added by the user with ID 84291986575613952 from the message.</para>
/// <code language="cs">
/// await msg.RemoveReactionAsync(new Emoji("\U0001f495"), 84291986575613952);
/// </code>
@@ -220,7 +220,7 @@ namespace Discord
/// Gets all users that reacted to a message with a given emote.
/// </summary>
/// <example>
/// The following example gets the users that have reacted with the emoji <c>💕</c> to the message.
/// <para>The following example gets the users that have reacted with the emoji <c>💕</c> to the message.</para>
/// <code language="cs">
/// var emoji = new Emoji("\U0001f495");
/// var reactedUsers = await message.GetReactionUsersAsync(emoji, 100).FlattenAsync();


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

@@ -17,7 +17,7 @@ namespace Discord
/// method and what properties are available, please refer to <see cref="MessageProperties"/>.
/// </remarks>
/// <example>
/// The following example replaces the content of the message with <c>Hello World!</c>.
/// <para>The following example replaces the content of the message with <c>Hello World!</c>.</para>
/// <code language="cs">
/// await msg.ModifyAsync(x =&gt; x.Content = "Hello World!");
/// </code>


+ 2
- 2
src/Discord.Net.Core/Entities/Users/IGuildUser.cs View File

@@ -72,8 +72,8 @@ namespace Discord
/// Gets the level permissions granted to this user to a given channel.
/// </summary>
/// <example>
/// The following example checks if the current user has the ability to send a message with attachment in
/// this channel; if so, uploads a file via <see cref="IMessageChannel.SendFileAsync(string, string, bool, Embed, RequestOptions, bool)"/>.
/// <para>The following example checks if the current user has the ability to send a message with attachment in
/// this channel; if so, uploads a file via <see cref="IMessageChannel.SendFileAsync(string, string, bool, Embed, RequestOptions, bool)"/>.</para>
/// <code language="cs">
/// if (currentUser?.GetPermissions(targetChannel)?.AttachFiles)
/// await targetChannel.SendFileAsync("fortnite.png");


+ 4
- 4
src/Discord.Net.Core/Entities/Users/IUser.cs View File

@@ -21,8 +21,8 @@ namespace Discord
/// example).
/// </remarks>
/// <example>
/// The following example attempts to retrieve the user's current avatar and send it to a channel; if one is
/// not set, a default avatar for this user will be returned instead.
/// <para>The following example attempts to retrieve the user's current avatar and send it to a channel; if one is
/// not set, a default avatar for this user will be returned instead.</para>
/// <code language="cs" region="GetAvatarUrl"
/// source="..\..\..\Discord.Net.Examples\Core\Entities\Users\IUser.Examples.cs"/>
/// </example>
@@ -90,8 +90,8 @@ namespace Discord
/// </note>
/// </remarks>
/// <example>
/// The following example attempts to send a direct message to the target user and logs the incident should
/// it fail.
/// <para>The following example attempts to send a direct message to the target user and logs the incident should
/// it fail.</para>
/// <code region="GetOrCreateDMChannelAsync" language="cs"
/// source="../../../Discord.Net.Examples/Core/Entities/Users/IUser.Examples.cs"/>
/// </example>


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

@@ -44,8 +44,8 @@ namespace Discord
/// Sends a file to this message channel with an optional caption.
/// </summary>
/// <example>
/// The following example uploads a streamed image that will be called <c>b1nzy.jpg</c> embedded inside a
/// rich embed to the channel.
/// <para>The following example uploads a streamed image that will be called <c>b1nzy.jpg</c> embedded inside a
/// rich embed to the channel.</para>
/// <code language="cs">
/// await channel.SendFileAsync(b1nzyStream, "b1nzy.jpg",
/// embed: new EmbedBuilder {ImageUrl = "attachment://b1nzy.jpg"}.Build());


Loading…
Cancel
Save