mirror of
https://github.com/Rapptz/discord.py.git
synced 2025-04-20 16:00:29 +00:00
Move Member.permissions_in to User.permissions_in.
This commit is contained in:
parent
654001ba3e
commit
86e9b62303
@ -103,19 +103,3 @@ class Member(User):
|
||||
# we switched channels
|
||||
if self.voice_channel is not None:
|
||||
self.voice_channel.voice_members.append(self)
|
||||
|
||||
def permissions_in(self, channel):
|
||||
"""An alias for :meth:`Channel.permissions_for`.
|
||||
|
||||
Basically equivalent to:
|
||||
|
||||
.. code-block:: python
|
||||
|
||||
channel.permissions_for(self)
|
||||
|
||||
Parameters
|
||||
-----------
|
||||
channel
|
||||
The channel to check your permissions for.
|
||||
"""
|
||||
return channel.permissions_for(self)
|
||||
|
@ -86,3 +86,19 @@ class User:
|
||||
"""Returns a string that allows you to mention the given user."""
|
||||
return '<@{0.id}>'.format(self)
|
||||
|
||||
def permissions_in(self, channel):
|
||||
"""An alias for :meth:`Channel.permissions_for`.
|
||||
|
||||
Basically equivalent to:
|
||||
|
||||
.. code-block:: python
|
||||
|
||||
channel.permissions_for(self)
|
||||
|
||||
Parameters
|
||||
-----------
|
||||
channel
|
||||
The channel to check your permissions for.
|
||||
"""
|
||||
return channel.permissions_for(self)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user