Don't assume that any shared fields are optional in Client.edit_channel.

Thanks Jake and night.
This commit is contained in:
Rapptz
2016-06-15 20:49:18 -04:00
parent eeba4963f3
commit 2ebc0ab218
2 changed files with 5 additions and 3 deletions

View File

@ -339,7 +339,7 @@ class HTTPClient:
def edit_channel(self, channel_id, **options):
url = '{0.CHANNELS}/{1}'.format(self, channel_id)
valid_keys = ('name', 'topic', 'bitrate', 'user_limit')
valid_keys = ('name', 'topic', 'bitrate', 'user_limit', 'position')
payload = {
k: v for k, v in options.items() if k in valid_keys
}