mirror of
https://github.com/Cog-Creators/Red-DiscordBot.git
synced 2025-12-05 17:02:32 -05:00
discord.py 2.0 update (3d914e08->2.0.1) (#5709)
This commit is contained in:
@@ -221,8 +221,8 @@ class Permissions(commands.Cog):
|
||||
"Global rules (set by the owner) are checked first, then rules set for servers. If "
|
||||
"multiple global or server rules apply to the case, the order they are checked in is:\n"
|
||||
" 1. Rules about a user.\n"
|
||||
" 2. Rules about the voice channel a user is in.\n"
|
||||
" 3. Rules about the text channel or a parent of the thread a command was issued in.\n"
|
||||
" 2. Rules about the voice channel a user is connected to.\n"
|
||||
" 3. Rules about the channel or a parent of the thread a command was issued in.\n"
|
||||
" 4. Rules about a role the user has (The highest role they have with a rule will be "
|
||||
"used).\n"
|
||||
" 5. Rules about the server a user is in (Global rules only).\n\n"
|
||||
@@ -330,7 +330,7 @@ class Permissions(commands.Cog):
|
||||
except discord.Forbidden:
|
||||
await ctx.send(_("I'm not allowed to DM you."))
|
||||
else:
|
||||
if not isinstance(ctx.channel, discord.DMChannel):
|
||||
if ctx.guild is not None:
|
||||
await ctx.send(_("I've just sent the file to you via DM."))
|
||||
finally:
|
||||
file.close()
|
||||
|
||||
Reference in New Issue
Block a user