KO round
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import { NextResponse } from "next/server";
|
||||
import { fetchMatchesAndTeams, fetchOdds, attachOdds, attachKOOdds, fetchLiveScores, applyLiveScores, assignKONumbersBySlots } from "@/lib/feeds";
|
||||
import { fetchMatchesAndTeams, fetchOdds, attachOdds, attachKOOdds, fetchLiveScores, applyLiveScores, assignKONumbersBySlots, fetchKOLiveData, attachKOLiveData } from "@/lib/feeds";
|
||||
import { computeGroupTables, computeThirdPlaceTable } from "@/lib/standings";
|
||||
import { qualifiedThirdGroups, resolveAnnexC } from "@/lib/bracket";
|
||||
import { securelyQualifiedThirdTeams } from "@/lib/third-place-security";
|
||||
@@ -39,6 +39,14 @@ export async function GET() {
|
||||
matches = attachKOOdds(matches, teams, odds);
|
||||
}
|
||||
|
||||
// KO-Live-Daten (Tore, Minute) von worldcup26
|
||||
try {
|
||||
const koGames = await fetchKOLiveData();
|
||||
matches = attachKOLiveData(matches, teams, koGames);
|
||||
} catch (err) {
|
||||
console.warn("[worldcup26] KO-Live-Daten fehlgeschlagen:", err instanceof Error ? err.message : err);
|
||||
}
|
||||
|
||||
const normalizedMatches = matches.map((m) => ({ ...m, prob: m.prob ?? null }));
|
||||
|
||||
const thirdTable = computeThirdPlaceTable(groupTablesLive);
|
||||
|
||||
Reference in New Issue
Block a user