From 180c645fdba5ec6d9d91750690e8ff85fe5a0b99 Mon Sep 17 00:00:00 2001 From: Daniel Karbach Date: Wed, 13 Apr 2022 00:16:08 +0200 Subject: [PATCH] copy rounds before reverse --- resources/js/helpers/Tournament.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/js/helpers/Tournament.js b/resources/js/helpers/Tournament.js index fac1681..dd87993 100644 --- a/resources/js/helpers/Tournament.js +++ b/resources/js/helpers/Tournament.js @@ -38,7 +38,7 @@ export const getScoreTable = tournament => { runners.forEach(participant => { running[participant.id] = 0; }); - const data = tournament.rounds.reverse().map(round => { + const data = [...tournament.rounds].reverse().map(round => { const entry = { number: `#${round.number}` }; runners.forEach(participant => { const result = Participant.findResult(participant, round); -- 2.39.2