1
0
mirror of https://github.com/immich-app/immich.git synced 2024-11-24 08:52:28 +02:00
immich/server
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
..
bin fix(admin-cli): Fixes immich-admin because npm bin does not like arguments (#3864) 2023-08-27 09:35:49 -05:00
openapi-generator fix(mobile): map markers not loading with int coordinates (#3957) 2023-09-05 06:08:43 +07:00
src fix(server): Correctly set album start and end dates (#4698) 2023-10-31 05:08:34 -05:00
test fix(server): Correctly set album start and end dates (#4698) 2023-10-31 05:08:34 -05:00
.dockerignore
.eslintrc.js fix(server,cli): don't float promises (#4433) 2023-10-13 01:22:40 -04:00
.gitignore
.prettierignore
.prettierrc fix(server): lint import order (#3974) 2023-09-04 21:45:59 +02:00
build-lock.json chore(deps): upgrade sharp and libvips (#4140) 2023-09-19 15:11:25 -04:00
Dockerfile chore(server,web): bump node version to 20.8 (#4311) 2023-10-03 09:34:35 -05:00
immich-openapi-specs.json chore(server): remove user count endpoint (#4724) 2023-10-30 19:29:18 +00:00
LICENSE
nest-cli.json
openapitools.json
package-lock.json Version v1.83.0 2023-10-28 13:32:48 +00:00
package.json Version v1.83.0 2023-10-28 13:32:48 +00:00
start-microservices.sh fix: shebangs (#3643) 2023-08-16 22:50:01 -05:00
start-server.sh fix: shebangs (#3643) 2023-08-16 22:50:01 -05:00
start.sh fix(admin-cli): Fixes immich-admin because npm bin does not like arguments (#3864) 2023-08-27 09:35:49 -05:00
tsconfig.build.json fix: exclude e2e format (#3250) 2023-07-13 21:41:16 -05:00
tsconfig.json fix(server): better fix for the OAuth Discovery errors (#4695) 2023-10-30 13:22:30 -04:00