if changes
This commit is contained in:
@@ -140,7 +140,7 @@ def list_patchnotes(since: str | None = None):
|
||||
)
|
||||
|
||||
# 3) Datum validieren (nur wenn vorhanden)
|
||||
if since:
|
||||
elif since:
|
||||
query = {
|
||||
"patch_date": {
|
||||
"$gte": last_login,
|
||||
@@ -155,10 +155,8 @@ def list_patchnotes(since: str | None = None):
|
||||
detail="since must be YYYY-MM-DD",
|
||||
status=400,
|
||||
)
|
||||
else:
|
||||
query = {} # erster Login → alle Notes
|
||||
|
||||
# 4) Patchnotes abholen
|
||||
|
||||
docs = list(collection.find(query).sort("patch_date", 1))
|
||||
for d in docs:
|
||||
d.pop("_id", None)
|
||||
@@ -235,5 +233,3 @@ def update_patchnote(patch_id, body): # noqa: E501
|
||||
mimetype="application/json",
|
||||
status=200,
|
||||
)
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user