fixed carbon updates, changed dark poke icon

This commit is contained in:
Master Kwoth 2016-04-12 03:07:51 +02:00
parent 3af13550c2
commit cc89d37ba5
2 changed files with 16 additions and 5 deletions

View File

@ -100,17 +100,28 @@ namespace NadekoBot
};
}
private void SendUpdateToCarbon()
private async Task SendUpdateToCarbon()
{
if (string.IsNullOrWhiteSpace(NadekoBot.Creds.CarbonKey))
return;
try
{
Console.WriteLine("Joined server.");
using (var client = new HttpClient())
{
client.PostAsync("https://www.carbonitex.net/discord/data/botdata.php",
new FormUrlEncodedContent(new Dictionary<string, string> {
using (var content = new FormUrlEncodedContent(new Dictionary<string, string> {
{ "servercount", NadekoBot.Client.Servers.Count().ToString() },
{ "key", NadekoBot.Creds.CarbonKey }
}));
}))
{
content.Headers.Clear();
content.Headers.Add("Content-Type", "application/x-www-form-urlencoded");
var res = await client.PostAsync("https://www.carbonitex.net/discord/data/botdata.php", content);
Console.WriteLine(res.ReasonPhrase);
Console.WriteLine(res.StatusCode);
};
}
}
catch (Exception ex)

View File

@ -618,7 +618,7 @@
"bite",
"faint attack"
],
"Icon": "🕶"
"Icon": ""
},
{
"Name": "STEEL",