mirror of
https://github.com/stijndcl/didier.git
synced 2026-04-07 23:55:46 +02:00
Fix broken time formatting, remove word field
This commit is contained in:
parent
cbd3030565
commit
ea4181eac0
9 changed files with 22085 additions and 12 deletions
|
|
@ -1,5 +1,14 @@
|
|||
import datetime
|
||||
import zoneinfo
|
||||
|
||||
__all__ = ["LOCAL_TIMEZONE"]
|
||||
__all__ = ["LOCAL_TIMEZONE", "today_only_date"]
|
||||
|
||||
LOCAL_TIMEZONE = zoneinfo.ZoneInfo("Europe/Brussels")
|
||||
|
||||
|
||||
def today_only_date() -> datetime.datetime:
|
||||
"""Mongo can't handle datetime.date, so we need datetime
|
||||
|
||||
We do, however, only care about the date, so remove all the rest
|
||||
"""
|
||||
return datetime.datetime.today().replace(hour=0, minute=0, second=0, microsecond=0)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue