Fix bug with edit_role and create_role not working.
This was due to an error in overzealous removal of code.
This commit is contained in:
parent
aecf0daf33
commit
879584b81a
@ -2051,10 +2051,14 @@ class Client:
|
|||||||
Editing the role failed.
|
Editing the role failed.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
colour = fields.get('colour')
|
||||||
|
if colour is None:
|
||||||
|
colour = fields.get('color', role.colour)
|
||||||
|
|
||||||
payload = {
|
payload = {
|
||||||
'name': fields.get('name', role.name),
|
'name': fields.get('name', role.name),
|
||||||
'permissions': fields.get('permissions', role.permissions).value,
|
'permissions': fields.get('permissions', role.permissions).value,
|
||||||
'color': color.value,
|
'color': colour.value,
|
||||||
'hoist': fields.get('hoist', role.hoist),
|
'hoist': fields.get('hoist', role.hoist),
|
||||||
'mentionable': fields.get('mentionable', role.mentionable)
|
'mentionable': fields.get('mentionable', role.mentionable)
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user