fix NotificationLevel being suppressed
This commit is contained in:
parent
6decfd1d1a
commit
5107583c5d
@ -1050,12 +1050,10 @@ class Guild(Hashable):
|
|||||||
fields['banner'] = banner
|
fields['banner'] = banner
|
||||||
fields['splash'] = splash
|
fields['splash'] = splash
|
||||||
|
|
||||||
try:
|
default_message_notifications = fields.get('default_notifications', self.default_notifications)
|
||||||
default_message_notifications = int(fields.pop('default_notifications'))
|
if not isinstance(default_message_notifications, NotificationLevel):
|
||||||
except (TypeError, KeyError):
|
raise InvalidArgument('default_notifications field must be of type NotificationLevel')
|
||||||
pass
|
fields['default_message_notifications'] = default_message_notifications.value
|
||||||
else:
|
|
||||||
fields['default_message_notifications'] = default_message_notifications
|
|
||||||
|
|
||||||
try:
|
try:
|
||||||
afk_channel = fields.pop('afk_channel')
|
afk_channel = fields.pop('afk_channel')
|
||||||
|
Loading…
x
Reference in New Issue
Block a user