mirror of
https://github.com/immich-app/immich.git
synced 2025-07-09 03:04:16 -04:00
fix(server): only generate memories for past years
This commit is contained in:
parent
5c879acd5b
commit
61ac256556
@ -27,7 +27,7 @@ export class MemoryService extends BaseService {
|
|||||||
userMap[user.id] = [user.id, ...partnerIds];
|
userMap[user.id] = [user.id, ...partnerIds];
|
||||||
}
|
}
|
||||||
|
|
||||||
const start = DateTime.utc().startOf('day').minus({ days: DAYS });
|
const start = DateTime.utc().startOf('day').minus({ days: DAYS }).minus({ years: 1 });
|
||||||
|
|
||||||
const state = await this.systemMetadataRepository.get(SystemMetadataKey.MEMORIES_STATE);
|
const state = await this.systemMetadataRepository.get(SystemMetadataKey.MEMORIES_STATE);
|
||||||
let lastOnThisDayDate = state?.lastOnThisDayDate ? DateTime.fromISO(state?.lastOnThisDayDate) : start;
|
let lastOnThisDayDate = state?.lastOnThisDayDate ? DateTime.fromISO(state?.lastOnThisDayDate) : start;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user