Merge pull request #20 from Kwoth/dev

Update
This commit is contained in:
samvaio 2016-12-02 07:10:15 +05:30 committed by GitHub
commit 00b4d17e22
2 changed files with 3 additions and 3 deletions

View File

@ -159,7 +159,7 @@ namespace NadekoBot.Modules.CustomReactions
{
var txtStream = await customReactions.GroupBy(cr => cr.Trigger)
.OrderBy(cr => cr.Key)
.Select(cr => new { Trigger = cr.Key, Responses = cr.Count() })
.Select(cr => new { Trigger = cr.Key, Responses = cr.Select(y => y.Response).ToList() })
.ToJson()
.ToStream()
.ConfigureAwait(false);
@ -173,7 +173,7 @@ namespace NadekoBot.Modules.CustomReactions
[NadekoCommand, Usage, Description, Aliases]
public async Task ListCustReactG(IUserMessage imsg, int page = 1)
{
var channel = (ITextChannel)imsg.Channel;
var channel = imsg.Channel as ITextChannel;
if (page < 1 || page > 10000)
return;
ConcurrentHashSet<CustomReaction> customReactions;

View File

@ -535,7 +535,7 @@ namespace NadekoBot.Modules.Searches
if (matches.Count == 0)
return null;
var match = matches[rng.Next(0, matches.Count)];
return matches[rng.Next(0, matches.Count)].Groups["url"].Value;
return "http:" + matches[rng.Next(0, matches.Count)].Groups["url"].Value;
}
}