Skip to content

Commit

Permalink
Fix sorting bugs in @scadenziario-day (#291)
Browse files Browse the repository at this point in the history
Co-authored-by: Luca <[email protected]>
  • Loading branch information
folix-01 and luca-bellenghi authored Jan 13, 2025
1 parent c46ae65 commit 436094f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 2 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ Changelog
[mamico]
- add SEO behavior to File
[mamico]
- Fix sorting in @scadenziario-day endpoint.
[folix-01]

6.3.1 (2024-12-12)
------------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -194,8 +194,8 @@ def reply(self):
if query is None:
raise Exception("No query supplied")

if sort_order:
sort_order = "descending" if sort_order else "ascending"
if sort_order not in {"descending", "ascending"}:
sort_order = "ascending"

# results = querybuilder(**querybuilder_parameters)
# Seems that origina querybuilder is not able to handle event search on
Expand Down Expand Up @@ -286,7 +286,6 @@ def reply(self):
}
)

results_to_be_returned[key].sort(key=lambda x: x["title"])
return {
"@id": self.request.get("URL"),
"items": results_to_be_returned,
Expand Down

0 comments on commit 436094f

Please sign in to comment.