From d72c843286ca7087066f3a02578dd227e735caf6 Mon Sep 17 00:00:00 2001 From: Andrew Blakeslee Moore Date: Mon, 6 Jul 2026 18:29:10 -0700 Subject: [PATCH] Transcript Incremental Projection Nucleic-Session: 0FFD007B-0696-4517-9429-129C7B0FD5AC Co-authored-by: Nucleic --- .../Transcript/IncrementalTranscriptProjection.swift | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/NucleicRemote/NucleicRemote/Views/Transcript/IncrementalTranscriptProjection.swift b/NucleicRemote/NucleicRemote/Views/Transcript/IncrementalTranscriptProjection.swift index 54a2ec6..7f76c9d 100644 --- a/NucleicRemote/NucleicRemote/Views/Transcript/IncrementalTranscriptProjection.swift +++ b/NucleicRemote/NucleicRemote/Views/Transcript/IncrementalTranscriptProjection.swift @@ -310,9 +310,11 @@ final class IncrementalTranscriptProjection { var runningMaxLast = -1 var best = 0 - for w in 1...min(cap, n - edgeLag) where w >= 1 { - runningMaxLast = max(runningMaxLast, maxLastAtFirst[w - 1]) - if separatorOK[w - 1] && runningMaxLast < w { best = w } + if cap >= 1 { + for w in 1...cap { + runningMaxLast = max(runningMaxLast, maxLastAtFirst[w - 1]) + if separatorOK[w - 1] && runningMaxLast < w { best = w } + } } return start + best }