From 34cc4a6cbb99ac39b126823943b94a14ce4ed618 Mon Sep 17 00:00:00 2001 From: Fahri Can Date: Tue, 5 May 2026 01:04:56 +0300 Subject: [PATCH] Update matches.service.ts --- src/modules/matches/matches.service.ts | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/src/modules/matches/matches.service.ts b/src/modules/matches/matches.service.ts index 3260ad8..4b4c93e 100755 --- a/src/modules/matches/matches.service.ts +++ b/src/modules/matches/matches.service.ts @@ -761,10 +761,19 @@ export class MatchesService { teamStats: normalizedTeamStats, mstUtc: Number(match.mstUtc), date: match.date || new Date(Number(match.mstUtc)), - // Ensure score is in expected format (nested object for frontend if needed, but frontend seems to use match.score.home in some places and match.scoreHome in others. - // The match-detail-content uses match.score.home. Match entity has scoreHome/scoreAway fields. - // Let's ensure compatibility. score: match.score || { home: match.scoreHome, away: match.scoreAway }, + homeTeam: { + ...match.homeTeam, + logo: match.homeTeamId + ? `https://file.mackolikfeeds.com/teams/${match.homeTeamId}` + : match.homeTeam?.logoUrl || null, + }, + awayTeam: { + ...match.awayTeam, + logo: match.awayTeamId + ? `https://file.mackolikfeeds.com/teams/${match.awayTeamId}` + : match.awayTeam?.logoUrl || null, + }, stats: { home: this.normalizeTeamStat(homeStat, match.sport), away: this.normalizeTeamStat(awayStat, match.sport),