fix(portals): keep a forced Stalker episode launch pending until it starts

The launch is awaited inside the start, so the pending state covers the
close of the previous player and the launch itself instead of clearing
as soon as the launch was kicked off.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
4grayandClaude Fable 5.1 committed 2026-10-03 12:07:48 +02:00
1 parent d0fe593f92
commit 23b70c524f
1 file changed
+14 -10
@@ -1306,16 +1306,20 @@ export class StalkerSeriesViewComponent implements OnDestroy {
}
this.closeInlinePlayer();
void (forcePlayer
? this.openEpisodeExternally(
resolvedPlayback,
forcePlayer,
request
)
: this.portalPlayer.openResolvedPlayback(
resolvedPlayback,
true
));
if (forcePlayer) {
// Awaited so the start stays pending through the close of the
// previous player and the launch itself.
await this.openEpisodeExternally(
resolvedPlayback,
forcePlayer,
request
);
} else {
void this.portalPlayer.openResolvedPlayback(
resolvedPlayback,
true
);
}
} catch (error) {
if (!this.isPlaybackRequestCurrent(request)) return;
this.logger.error('Failed to start inline series playback', error);