diff --git a/discord/gateway.py b/discord/gateway.py index 735544930..afac2c031 100644 --- a/discord/gateway.py +++ b/discord/gateway.py @@ -599,7 +599,9 @@ class DiscordWebSocket: if activity is not None: if not isinstance(activity, BaseActivity): raise InvalidArgument('activity must derive from BaseActivity.') - activity = activity.to_dict() + activity = [activity.to_dict()] + else: + activity = [] if status == 'idle': since = int(time.time() * 1000) @@ -607,7 +609,7 @@ class DiscordWebSocket: payload = { 'op': self.PRESENCE, 'd': { - 'activities': [activity], + 'activities': activity, 'afk': afk, 'since': since, 'status': status