Fix wrong test on filtering user
All checks were successful
divent / lint (push) Successful in 2m6s
divent / docker (push) Successful in 2m10s
divent / pypi (push) Has been skipped

This commit is contained in:
Michel Roux 2023-11-07 02:37:08 +01:00
parent f7779ace60
commit 96ac519fde

View File

@ -303,10 +303,10 @@ async def ical(entity_id: str):
for guild in client.guilds:
if await guild.get_or_fetch_member(int(entity_id)):
for scheduled_event in guild.scheduled_events:
if user.id in [
member.id
if any(
user.id == member.id
for member in await scheduled_event.fetch_users().flatten()
]:
):
event = make_event(scheduled_event)
calendar.events.append(event)