diff options
| author | jack1142 <[email protected]> | 2020-03-28 03:48:55 +0100 |
|---|---|---|
| committer | Rapptz <[email protected]> | 2020-04-04 01:12:46 -0400 |
| commit | 7b3335a0b0d770f7d572f8672903e1435bb1faa3 (patch) | |
| tree | 23f41a53f5179c0c2b6a39f1f6569723b7955fcc | |
| parent | Add "FEATURABLE" in guild features. (diff) | |
| download | discord.py-7b3335a0b0d770f7d572f8672903e1435bb1faa3.tar.xz discord.py-7b3335a0b0d770f7d572f8672903e1435bb1faa3.zip | |
Don't add None to Member.activities tuple
| -rw-r--r-- | discord/client.py | 3 | ||||
| -rw-r--r-- | discord/shard.py | 3 |
2 files changed, 4 insertions, 2 deletions
diff --git a/discord/client.py b/discord/client.py index 00465797..e0f74192 100644 --- a/discord/client.py +++ b/discord/client.py @@ -947,7 +947,8 @@ class Client: if me is None: continue - me.activities = (activity,) + if activity is not None: + me.activities = (activity,) me.status = status_enum # Guild stuff diff --git a/discord/shard.py b/discord/shard.py index 53c09c0d..2ea59dbc 100644 --- a/discord/shard.py +++ b/discord/shard.py @@ -353,5 +353,6 @@ class AutoShardedClient(Client): if me is None: continue - me.activities = (activity,) + if activity is not None: + me.activities = (activity,) me.status = status_enum |