mirror of
https://github.com/Rapptz/discord.py.git
synced 2025-06-07 12:18:59 +00:00
Fix Client.create_role
This commit is contained in:
parent
7161723034
commit
ad6fbbfe43
@ -1234,10 +1234,11 @@ class Client(object):
|
|||||||
data = response.json()
|
data = response.json()
|
||||||
everyone = server.id == data.get('id')
|
everyone = server.id == data.get('id')
|
||||||
role = Role(everyone=everyone, **data)
|
role = Role(everyone=everyone, **data)
|
||||||
if self.edit_role(server, role, **fields):
|
|
||||||
# we have to call edit because you can't pass a payload to the
|
# we have to call edit because you can't pass a payload to the
|
||||||
# http request currently.
|
# http request currently.
|
||||||
return role
|
self.edit_role(server, role, **fields)
|
||||||
|
return role
|
||||||
|
|
||||||
def set_channel_permissions(self, channel, target, allow=None, deny=None):
|
def set_channel_permissions(self, channel, target, allow=None, deny=None):
|
||||||
"""Sets the channel specific permission overwrites for a target in the
|
"""Sets the channel specific permission overwrites for a target in the
|
||||||
|
Loading…
x
Reference in New Issue
Block a user