]> git.localhorst.tv Git - alttp.git/blobdiff - resources/js/components/pages/Tournament.js
lock tournaments
[alttp.git] / resources / js / components / pages / Tournament.js
index d5df3a1ca4916e4cae6a17c55df1c76babee86a0..11dc388c67d60c3832a977a7265a93033b7010ee 100644 (file)
@@ -52,6 +52,11 @@ const Tournament = () => {
                                if (e.round) {
                                        setTournament(tournament => patchRound(tournament, e.round));
                                }
+                       })
+                       .listen('TournamentChanged', e => {
+                               if (e.tournament) {
+                                       setTournament(tournament => ({ ...tournament, ...e.tournament }));
+                               }
                        });
                return () => {
                        window.Echo.leave(`Tournament.${id}`);