From edcd9459e3d04c8379359ff30391afe3cfa5e5ab Mon Sep 17 00:00:00 2001 From: Rapptz Date: Wed, 10 Jul 2019 14:39:12 -0400 Subject: [PATCH] Use Guild.owner_id in Guild.edit when checking if the bot owns a guild. --- discord/guild.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/discord/guild.py b/discord/guild.py index 2cf1acadc..4c87e9f02 100644 --- a/discord/guild.py +++ b/discord/guild.py @@ -1095,7 +1095,7 @@ class Guild(Hashable): fields['system_channel_id'] = system_channel.id if 'owner' in fields: - if self.owner != self.me: + if self.owner_id != self._state.self_id: raise InvalidArgument('To transfer ownership you must be the owner of the guild.') fields['owner_id'] = fields['owner'].id