fix: keep best-of-three grand finals open for results

Allow a separate grand final format and repair prematurely completed finals without dropping accepted games. Replay the correction record alongside subsequent results.
This commit is contained in:
dahyeon committed 2026-11-10 18:49:26 +09:00
1 parent 38a89b5374
commit 7e0cd7cb19
21 files changed
+914 -23

No files matched your search

@@ -21,7 +21,7 @@ interface PublicMatchSource {
gameCount: number;
gameMode: MatchGameMode;
roundRobinMaxRounds?: number;
doubleElimination?: { resetFinalEnabled?: boolean };
doubleElimination?: { resetFinalEnabled?: boolean; grandFinalGameCount?: 1 | 3 | 5 };
hostUserId?: IdLike;
participants: Array<{
userId: IdLike;
@@ -81,6 +81,8 @@ export function presentPublicMatch(
? {
doubleEliminationResetFinalEnabled:
source.doubleElimination?.resetFinalEnabled ?? false,
doubleEliminationGrandFinalGameCount:
source.doubleElimination?.grandFinalGameCount ?? 1,
}
: {}),
...(source.hostUserId