0
Fork 0
mirror of https://github.com/immich-app/immich.git synced 2025-02-04 01:09:14 -05:00
immich/server/src
Michael Manganiello b6f18cbe81
fix(server): Correctly set album start and end dates (#4698)
* fix(server): Correctly set album start and end dates

Currently, the query that retrieves album assets uses
`ORDER BY assets.fileCreatedAt DESC`, which makes the existing logic
return the start/end dates reversed (with `startDate` being taken from
the first asset in the array).

Instead of using the index-based approach, this change iterates through
assets to get the min/max `fileCreatedAt`. This will avoid any future
issues, if the query ordering changes, or becomes customizable (e.g. in
case the user prefers to visualize older assets first).

* fix: Maintain constant cost and only swap variables if needed
2023-10-31 05:08:34 -05:00
..
admin-cli chore(server): bump server dependencies (#3899) 2023-08-28 14:41:57 -05:00
domain fix(server): Correctly set album start and end dates (#4698) 2023-10-31 05:08:34 -05:00
immich refactor(server): user profile picture (#4728) 2023-10-30 19:38:34 -04:00
infra fix(web): multiple improvements for people page (1) (#4717) 2023-10-30 14:40:28 -05:00
microservices refactor(server, web)!: store latest immich version available on the server (#3565) 2023-10-24 11:05:42 -04:00
main.ts fix(server,cli): don't float promises (#4433) 2023-10-13 01:22:40 -04:00