diff --git a/src/renderer/src/components/right-sidebar/checks-panel-hosted-review-click-routing.test.ts b/src/renderer/src/components/right-sidebar/checks-panel-hosted-review-click-routing.test.ts index 4f517517652..956877a7cd7 100644 --- a/src/renderer/src/components/right-sidebar/checks-panel-hosted-review-click-routing.test.ts +++ b/src/renderer/src/components/right-sidebar/checks-panel-hosted-review-click-routing.test.ts @@ -132,6 +132,21 @@ describe('checks panel hosted review modifier hint destination', () => { ).toBeNull() }) + // Why: openHttpLink trims before treating a runtime as active, so a blank id must + // not suppress a hint for a click that still reaches Orca. + it('ignores a blank runtime id', () => { + expect( + resolveChecksPanelHostedReviewModifierDestination( + { + openLinksInApp: false, + openLinksInAppModifierInverts: true, + activeRuntimeEnvironmentId: ' ' + }, + true + ) + ).toBe('orca') + }) + // Why: openHttpLink gates routing to Orca on a worktree id, so without one the // modifier lands in the system browser either way. it('stays silent without a worktree', () => { diff --git a/src/renderer/src/components/right-sidebar/checks-panel-hosted-review-click-routing.ts b/src/renderer/src/components/right-sidebar/checks-panel-hosted-review-click-routing.ts index 65e5ebea8ed..62ddcb71b4e 100644 --- a/src/renderer/src/components/right-sidebar/checks-panel-hosted-review-click-routing.ts +++ b/src/renderer/src/components/right-sidebar/checks-panel-hosted-review-click-routing.ts @@ -38,7 +38,9 @@ export function resolveChecksPanelHostedReviewModifierDestination( | undefined, hasWorktree: boolean ): ChecksPanelHostedReviewModifierDestination { - if (!hasWorktree || settings?.activeRuntimeEnvironmentId) { + // Why: trim to match openHttpLink — an untrimmed check hides the hint on a blank + // runtime id while the click still routes to Orca. + if (!hasWorktree || settings?.activeRuntimeEnvironmentId?.trim()) { return null } if (settings?.openLinksInApp === true) {