ban is pruning for 7 days, fixed .whoplays
This commit is contained in:
parent
ad358b5e0f
commit
7c3bf15809
@ -302,7 +302,7 @@ namespace NadekoBot.Modules.Administration
|
|||||||
}
|
}
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
await e.Server.Ban(usr).ConfigureAwait(false);
|
await e.Server.Ban(usr, 7).ConfigureAwait(false);
|
||||||
|
|
||||||
await e.Channel.SendMessage("Banned user " + usr.Name + " Id: " + usr.Id).ConfigureAwait(false);
|
await e.Channel.SendMessage("Banned user " + usr.Name + " Id: " + usr.Id).ConfigureAwait(false);
|
||||||
}
|
}
|
||||||
@ -986,7 +986,7 @@ namespace NadekoBot.Modules.Administration
|
|||||||
if (string.IsNullOrWhiteSpace(game))
|
if (string.IsNullOrWhiteSpace(game))
|
||||||
return;
|
return;
|
||||||
var en = e.Server.Users
|
var en = e.Server.Users
|
||||||
.Where(u => u.CurrentGame?.Name.ToUpperInvariant() == game)
|
.Where(u => u.CurrentGame?.Name?.ToUpperInvariant() == game)
|
||||||
.Select(u => $"{u.Name}");
|
.Select(u => $"{u.Name}");
|
||||||
|
|
||||||
var arr = en as string[] ?? en.ToArray();
|
var arr = en as string[] ?? en.ToArray();
|
||||||
|
@ -86,7 +86,7 @@ namespace NadekoBot.Modules.Administration.Commands
|
|||||||
if (!string.IsNullOrWhiteSpace(user.Nickname))
|
if (!string.IsNullOrWhiteSpace(user.Nickname))
|
||||||
sb.AppendLine($"`Nickname:` **{user.Nickname}**");
|
sb.AppendLine($"`Nickname:` **{user.Nickname}**");
|
||||||
sb.AppendLine($"`Id:` **{user.Id}**");
|
sb.AppendLine($"`Id:` **{user.Id}**");
|
||||||
sb.AppendLine($"`Current Game:` **{(user.CurrentGame == null ? "-" : user.CurrentGame.Value.Name)}**");
|
sb.AppendLine($"`Current Game:` **{(user.CurrentGame?.Name == null ? "-" : user.CurrentGame.Value.Name)}**");
|
||||||
if (user.LastOnlineAt != null)
|
if (user.LastOnlineAt != null)
|
||||||
sb.AppendLine($"`Last Online:` **{user.LastOnlineAt:HH:mm:ss}**");
|
sb.AppendLine($"`Last Online:` **{user.LastOnlineAt:HH:mm:ss}**");
|
||||||
sb.AppendLine($"`Joined At:` **{user.JoinedAt}**");
|
sb.AppendLine($"`Joined At:` **{user.JoinedAt}**");
|
||||||
|
Loading…
Reference in New Issue
Block a user