Browse Source

Fix bug with edit_role and create_role not working.

This was due to an error in overzealous removal of code.
pull/244/head
Rapptz 9 years ago
parent
commit
879584b81a
  1. 6
      discord/client.py

6
discord/client.py

@ -2051,10 +2051,14 @@ class Client:
Editing the role failed.
"""
colour = fields.get('colour')
if colour is None:
colour = fields.get('color', role.colour)
payload = {
'name': fields.get('name', role.name),
'permissions': fields.get('permissions', role.permissions).value,
'color': color.value,
'color': colour.value,
'hoist': fields.get('hoist', role.hoist),
'mentionable': fields.get('mentionable', role.mentionable)
}

Loading…
Cancel
Save