From c8a135a7ae53cf650a91916f77c0ca7b43b04a86 Mon Sep 17 00:00:00 2001 From: Alex Date: Thu, 19 Jun 2025 09:59:14 -0500 Subject: [PATCH] fix: .find() iterator api combat (#19293) * fix: .find() iterator api combar * Update web/src/lib/managers/timeline-manager/month-group.svelte.ts Co-authored-by: Daniel Dietzler <36593685+danieldietzler@users.noreply.github.com> --------- Co-authored-by: Daniel Dietzler <36593685+danieldietzler@users.noreply.github.com> --- web/src/lib/managers/timeline-manager/month-group.svelte.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/web/src/lib/managers/timeline-manager/month-group.svelte.ts b/web/src/lib/managers/timeline-manager/month-group.svelte.ts index f18a1e6413..bbcfe88caa 100644 --- a/web/src/lib/managers/timeline-manager/month-group.svelte.ts +++ b/web/src/lib/managers/timeline-manager/month-group.svelte.ts @@ -343,7 +343,11 @@ export class MonthGroup { } findAssetById(assetDescriptor: AssetDescriptor) { - return this.assetsIterator().find((asset) => asset.id === assetDescriptor.id); + for (const asset of this.assetsIterator()) { + if (asset.id === assetDescriptor.id) { + return asset; + } + } } findClosest(target: TimelinePlainDateTime) {