Prevent KeyError when removing scheduled event user

This commit is contained in:
Nadir Chowdhury 2022-03-12 01:50:49 +00:00 committed by GitHub
parent 206c340252
commit c95d12dcfc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -566,4 +566,4 @@ class ScheduledEvent(Hashable):
self._users[user.id] = user
def _pop_user(self, user_id: int) -> None:
self._users.pop(user_id)
self._users.pop(user_id, None)