Fix retrieving photos from Immich with timeframes

This commit is contained in:
Eugene Burmakin 2024-11-27 16:43:12 +01:00
parent 699a3de57c
commit 3ba7a657e4
3 changed files with 9 additions and 3 deletions

View file

@ -1 +1 @@
0.17.1
0.17.2

View file

@ -9,6 +9,12 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
### Fixed
- Retrieving photos from Immich now using `takenAfter` and `takenBefore` instead of `createdAfter` and `createdBefore`. With `createdAfter` and `createdBefore` Immich was returning no items some years.
# 0.17.1 - 2024-11-27
### Fixed
- Retrieving photos from Immich now correctly handles cases when Immich returns no items. It also logs the response from Immich for debugging purposes.
# 0.17.0 - 2024-11-26

View file

@ -61,7 +61,7 @@ class Immich::RequestPhotos
def request_body(page)
body = {
createdAfter: start_date,
takenAfter: start_date,
size: 1000,
page: page,
order: 'asc',
@ -70,7 +70,7 @@ class Immich::RequestPhotos
return body unless end_date
body.merge(createdBefore: end_date)
body.merge(takenBefore: end_date)
end
def time_framed_data(data)