Fix timer not showing

This commit is contained in:
Daniel Schädler 2025-03-13 13:33:35 +01:00
parent 5c27eccf3d
commit 2243d3e7dd
1 changed files with 1 additions and 6 deletions

View File

@ -141,12 +141,7 @@ class Main extends React.Component {
updateTimerEnd() {
const tournamentId = this.props.query.code;
getTournamentTimerEnd(tournamentId, (status, timerEnd) => {
const now = new Date();
if (timerEnd > now) {
this.setState({timerEnd: timerEnd});
} else {
this.setState({timerEnd: null});
}
this.setState({timerEnd: timerEnd});
}, error => {
console.error('Failed to fetch timer end:', error);
});