Skip to content

Commit

Permalink
fix other datetimes
Browse files Browse the repository at this point in the history
  • Loading branch information
jefer94 committed Jun 21, 2024
1 parent 0ca5594 commit c6eff0a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion breathecode/celery.py
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ def __exit__(self, *args, **kwargs):
data[i] = []

if len(data[i]) >= 2:
data[i].sort(key=lambda x: x['created_at'])
data[i].sort(key=lambda x: x['created_at'].replace(tzinfo=UTC))

if datetime.now(UTC) - data[i][-1]['created_at'].replace(tzinfo=UTC) < delta:
available[i] = False
Expand Down

0 comments on commit c6eff0a

Please sign in to comment.