From 9f47d7f71c5f42d5f1957cdb53c76841c45327a6 Mon Sep 17 00:00:00 2001 From: Rapptz Date: Thu, 16 Apr 2020 23:30:59 -0400 Subject: [PATCH] Fix cases where member_count is equal to 0 Fixes #4008, #4005 --- discord/guild.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/discord/guild.py b/discord/guild.py index 71ca954db..204d617ed 100644 --- a/discord/guild.py +++ b/discord/guild.py @@ -257,7 +257,7 @@ class Guild(Hashable): # according to Stan, this is always available even if the guild is unavailable # I don't have this guarantee when someone updates the guild. member_count = guild.get('member_count', None) - if member_count: + if member_count is not None: self._member_count = member_count self.name = guild.get('name')