Skip to content

Commit

Permalink
chore: switch from depricated utcnow()
Browse files Browse the repository at this point in the history
  • Loading branch information
leon-schmid committed Nov 13, 2024
1 parent 93f1c58 commit 3aa6d25
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions admyral/utils/time.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
from datetime import datetime
from datetime import datetime, timezone


def utc_now() -> datetime:
return datetime.utcnow()
return datetime.now(timezone.utc)


def utc_now_timestamp_seconds() -> int:
return int(datetime.utcnow().timestamp())
return int(datetime.now(timezone.utc).timestamp())

0 comments on commit 3aa6d25

Please sign in to comment.