Skip to content

Commit

Permalink
Actually parse the time in the detected_at methods
Browse files Browse the repository at this point in the history
Co-authored-by: owocado <24418520+owocado@users.noreply.github.com>
  • Loading branch information
Soheab and owocado committed Apr 27, 2024
1 parent cfe4137 commit 524ca79
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions discord/guild.py
Expand Up @@ -4425,7 +4425,7 @@ def dm_spam_detected_at(self) -> Optional[datetime.datetime]:
if not self._incidents_data:
return None

return self._incidents_data.get('dm_spam_detected_at', None)
return utils.parse_time(self._incidents_data.get('dm_spam_detected_at'))

@property
def raid_detected_at(self) -> Optional[datetime.datetime]:
Expand All @@ -4436,7 +4436,7 @@ def raid_detected_at(self) -> Optional[datetime.datetime]:
if not self._incidents_data:
return None

return self._incidents_data.get('raid_detected_at', None)
return utils.parse_time(self._incidents_data.get('raid_detected_at'))

def invites_paused(self) -> bool:
""":class:`bool`: Whether invites are paused in the guild.
Expand Down

0 comments on commit 524ca79

Please sign in to comment.