aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRapptz <[email protected]>2016-06-15 20:31:13 -0400
committerRapptz <[email protected]>2016-06-15 20:31:13 -0400
commiteeba4963f33fc1b09f3aee0b3fd1a93828ee29b1 (patch)
tree99e54d53edfa04a9f7cf5f2c4dcbb6e0b47aad2e
parentMake logging for HTTP requests more useful. (diff)
downloaddiscord.py-eeba4963f33fc1b09f3aee0b3fd1a93828ee29b1.tar.xz
discord.py-eeba4963f33fc1b09f3aee0b3fd1a93828ee29b1.zip
The name is required in Client.edit_channel so add it if it is missing.
-rw-r--r--discord/client.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/discord/client.py b/discord/client.py
index d7767180..c725da91 100644
--- a/discord/client.py
+++ b/discord/client.py
@@ -1522,6 +1522,9 @@ class Client:
Editing the channel failed.
"""
+ if 'name' not in options:
+ options['name'] = channel.name
+
yield from self.http.edit_channel(channel.id, **options)
@asyncio.coroutine