From b152f6fd856e79d5dbffbd520be986cdcb020016 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?William=20S=C3=B6derberg?= Date: Sun, 22 Feb 2026 22:24:10 +0100 Subject: [PATCH] Ghost match fix --- backend/app/core/brackets.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/backend/app/core/brackets.py b/backend/app/core/brackets.py index bad0094..01b1962 100644 --- a/backend/app/core/brackets.py +++ b/backend/app/core/brackets.py @@ -197,8 +197,8 @@ class BracketGenerator: loser = None # Ghost if p1_is_ghost and p2_is_ghost: - winner = None - loser = None + winner = p1 + loser = p2 elif p1_is_ghost: winner = p2 loser = p1 @@ -211,8 +211,5 @@ class BracketGenerator: m.next_win.teams[m.next_win_slot] = winner # Propagate Loser (Drop to LB) - # Important: We push the GHOST to the LB. - # When the loop reaches that LB match later, it will see the ghost - # and mark THAT match as a bye too, recursively cleaning the bracket. if m.next_loss: m.next_loss.teams[m.next_loss_slot] = loser