diff --git a/NadekoBot/Commands/HelpCommand.cs b/NadekoBot/Commands/HelpCommand.cs index 593f58a8..1c26806a 100644 --- a/NadekoBot/Commands/HelpCommand.cs +++ b/NadekoBot/Commands/HelpCommand.cs @@ -26,10 +26,10 @@ namespace NadekoBot while (helpstr.Length > 2000) { var curstr = helpstr.Substring(0, 2000); - await client.SendPrivateMessage(e.User, curstr.Substring(0, curstr.LastIndexOf("\n")+1)); + await client.SendMessage(e.User, curstr.Substring(0, curstr.LastIndexOf("\n")+1)); helpstr = curstr.Substring(curstr.LastIndexOf("\n")+1) + helpstr.Substring(2000); } - await client.SendPrivateMessage(e.User, helpstr); + await client.SendMessage(e.User, helpstr); }; } diff --git a/NadekoBot/Modules/Administration.cs b/NadekoBot/Modules/Administration.cs index 30ccbb60..9e3c5acc 100644 --- a/NadekoBot/Modules/Administration.cs +++ b/NadekoBot/Modules/Administration.cs @@ -40,7 +40,7 @@ namespace NadekoBot.Modules try { - await client.EditUser(usr, null, null, new Discord.Role[] { role }, Discord.EditMode.Add); + await client.EditUser(usr, null, null,null, new Discord.Role[] { role }, Discord.EditMode.Add); await e.Send( $"Successfully added role **{role.Name}** to user **{usr.Mention}**"); } catch (InvalidOperationException) { //fkin voltana and his shenanigans, fix role.Mention pl0x @@ -75,7 +75,7 @@ namespace NadekoBot.Modules try { - await client.EditUser(usr, null, null, new Discord.Role[]{ role }, Discord.EditMode.Remove); + await client.EditUser(usr, null, null,null, new Discord.Role[]{ role }, Discord.EditMode.Remove); await e.Send( $"Successfully removed role **{role.Name}** from user **{usr.Mention}**"); } catch (InvalidOperationException) { diff --git a/NadekoBot/Modules/Conversations.cs b/NadekoBot/Modules/Conversations.cs index 330ef62c..f49a6694 100644 --- a/NadekoBot/Modules/Conversations.cs +++ b/NadekoBot/Modules/Conversations.cs @@ -343,7 +343,7 @@ namespace NadekoBot.Modules f.Read(b, 0, b.Length); f.Close(); string str = Encoding.ASCII.GetString(b); - await client.SendPrivateMessage(e.User, "```" + (str.Length < 1950 ? str : str.Substring(0, 1950)) + "```"); + await client.SendMessage(e.User, "```" + (str.Length < 1950 ? str : str.Substring(0, 1950)) + "```"); }); CreateCommand(cgb, "cs") @@ -392,9 +392,9 @@ namespace NadekoBot.Modules { string str = StatsCollector.GetRequests(); if (str.Trim().Length > 110) - await client.SendPrivateMessage(e.User, str); + await client.SendMessage(e.User, str); else - await client.SendPrivateMessage(e.User, "No requests atm."); + await client.SendMessage(e.User, "No requests atm."); }); CreateCommand(cgb, "dr") @@ -436,7 +436,7 @@ namespace NadekoBot.Modules if (sc != null) { await e.Send(e.User.Mention + " Request resolved, notice sent."); - await client.SendPrivateMessage(client.GetUser(client.GetServer(sc.ServerId), sc.Id), "**This request of yours has been resolved:**\n" + sc.Text); + await client.SendMessage(client.GetUser(client.GetServer(sc.ServerId), sc.Id), "**This request of yours has been resolved:**\n" + sc.Text); } else { @@ -530,11 +530,12 @@ namespace NadekoBot.Modules foreach (var s in client.AllServers) { try { - i++; - var invite = await client.CreateInvite(e.Channel, 0, 0); + var invite = await client.CreateInvite(s, 0, 0); invites+=invite.Url+"\n"; + i++; } - catch (Exception) { + catch (Exception ex) { + Console.WriteLine(ex.ToString()); j++; continue; }