From 712ac2343a7d059a6d871ae145b0f956b1d04234 Mon Sep 17 00:00:00 2001 From: RogueException Date: Sun, 18 Oct 2015 09:24:56 -0300 Subject: [PATCH] Removed SendMessage's mentionedUsers parameter. --- src/Discord.Net/DiscordClient.API.cs | 24 ++++++------------------ 1 file changed, 6 insertions(+), 18 deletions(-) diff --git a/src/Discord.Net/DiscordClient.API.cs b/src/Discord.Net/DiscordClient.API.cs index ae04de4b4..a90898415 100644 --- a/src/Discord.Net/DiscordClient.API.cs +++ b/src/Discord.Net/DiscordClient.API.cs @@ -270,24 +270,12 @@ namespace Discord } //Messages - /// Sends a message to the provided channel, optionally mentioning certain users. - /// While not required, it is recommended to include a mention reference in the text (see User.Mention). - public Task SendMessage(Channel channel, string text, IEnumerable mentionedUsers = null) - => SendMessage(channel, text, mentionedUsers, false); - /// Sends a message to the provided channel, optionally mentioning certain users. - /// While not required, it is recommended to include a mention reference in the text (see User.Mention). - public Task SendMessage(string channelId, string text, IEnumerable mentionedUsers = null) - => SendMessage(_channels[channelId], text, mentionedUsers, false); - /// Sends a message to the provided channel, optionally mentioning certain users. - /// While not required, it is recommended to include a mention reference in the text (see User.Mention). - public Task SendTTSMessage(Channel channel, string text, IEnumerable mentionedUsers = null) - => SendMessage(channel, text, mentionedUsers, true); - /// Sends a message to the provided channel, optionally mentioning certain users. - /// While not required, it is recommended to include a mention reference in the text (see User.Mention). - public Task SendTTSMessage(string channelId, string text, IEnumerable mentionedUsers = null) - => SendMessage(_channels[channelId], text, mentionedUsers, true); - /// Sends a message to the provided channel, optionally mentioning certain users. - /// While not required, it is recommended to include a mention reference in the text (see User.Mention). + /// Sends a message to the provided channel. To include a mention, see the Mention static helper class. + public Task SendMessage(Channel channel, string text) + => SendMessage(channel, text, MentionHelper.GetUserIds(text), false); + /// Sends a message to the provided channel. To include a mention, see the Mention static helper class. + public Task SendMessage(string channelId, string text) + => SendMessage(_channels[channelId], text, MentionHelper.GetUserIds(text), false); private async Task SendMessage(Channel channel, string text, IEnumerable mentionedUsers = null, bool isTextToSpeech = false) { CheckReady();