Skip to content
This repository was archived by the owner on Aug 28, 2021. It is now read-only.
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion discord/ext/events/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ async def fetch_recent_audit_log_entry(client: discord.Client, guild: discord.Gu
"""
async for entry in guild.audit_logs(limit=1, action=action):

delta = datetime.datetime.utcnow() - entry.created_at
delta = discord.utils.utcnow() - entry.created_at
if delta < datetime.timedelta(seconds=10):
if target is not None and entry.target != target:
continue
Expand Down