Fixes to v+t and blacklisting
This commit is contained in:
parent
ee1a7931ee
commit
e8f6054c5a
@ -114,7 +114,7 @@ namespace NadekoBot.Modules.Administration
|
|||||||
var channel = (ITextChannel)msg.Channel;
|
var channel = (ITextChannel)msg.Channel;
|
||||||
var guild = channel.Guild;
|
var guild = channel.Guild;
|
||||||
|
|
||||||
var botUser = guild.GetCurrentUser();
|
var botUser = await guild.GetCurrentUserAsync().ConfigureAwait(false);
|
||||||
if (!botUser.GuildPermissions.ManageRoles || !botUser.GuildPermissions.ManageChannels)
|
if (!botUser.GuildPermissions.ManageRoles || !botUser.GuildPermissions.ManageChannels)
|
||||||
{
|
{
|
||||||
await channel.SendMessageAsync(":anger: `I require atleast manage roles and manage channels permissions to enable this feature (preffered Administration permission).`");
|
await channel.SendMessageAsync(":anger: `I require atleast manage roles and manage channels permissions to enable this feature (preffered Administration permission).`");
|
||||||
@ -166,7 +166,8 @@ namespace NadekoBot.Modules.Administration
|
|||||||
{
|
{
|
||||||
var channel = (ITextChannel)msg.Channel;
|
var channel = (ITextChannel)msg.Channel;
|
||||||
var guild = channel.Guild;
|
var guild = channel.Guild;
|
||||||
if (!guild.GetCurrentUser().GuildPermissions.Administrator)
|
var botUser = await guild.GetCurrentUserAsync().ConfigureAwait(false);
|
||||||
|
if (!botUser.GuildPermissions.Administrator)
|
||||||
{
|
{
|
||||||
await channel.SendMessageAsync("`I need Administrator permission to do that.`").ConfigureAwait(false);
|
await channel.SendMessageAsync("`I need Administrator permission to do that.`").ConfigureAwait(false);
|
||||||
return;
|
return;
|
||||||
|
@ -80,7 +80,7 @@ namespace NadekoBot.Modules.Permissions
|
|||||||
}
|
}
|
||||||
await uow.CompleteAsync().ConfigureAwait(false);
|
await uow.CompleteAsync().ConfigureAwait(false);
|
||||||
}
|
}
|
||||||
if (action == AddRemove.Rem)
|
if (action == AddRemove.Add)
|
||||||
{
|
{
|
||||||
TriviaGame tg;
|
TriviaGame tg;
|
||||||
switch (type)
|
switch (type)
|
||||||
|
Loading…
Reference in New Issue
Block a user