From 1698c5d71e3c2e7b322946b2716dff7127626343 Mon Sep 17 00:00:00 2001 From: Exerra Date: Tue, 14 Jul 2026 00:48:29 +0300 Subject: [PATCH] refactor(AppleMusicSource): clarify timestamp calculation logic Updated comments in applyCalculatedTimestamps to reflect that Apple Music lacks track timestamps, necessitating a hacky estimation method. --- src/backend/sources/AppleMusicSource.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/backend/sources/AppleMusicSource.ts b/src/backend/sources/AppleMusicSource.ts index 0777048a..03210fa0 100644 --- a/src/backend/sources/AppleMusicSource.ts +++ b/src/backend/sources/AppleMusicSource.ts @@ -169,8 +169,8 @@ export default class AppleMusicSource extends AbstractSource { } } } - - // Extract the reduceRight logic: + + // Apple Music does not provide timestamps for recently played tracks, so hacky method private applyCalculatedTimestamps(plays: PlayObject[]): PlayObject[] { let durSinceNow = 0; const now = dayjs(); -- 2.51.2