diff --git a/frontend/src/pages/levelList.tsx b/frontend/src/pages/levelList.tsx index d194e75..74fb7c1 100644 --- a/frontend/src/pages/levelList.tsx +++ b/frontend/src/pages/levelList.tsx @@ -44,7 +44,7 @@ const LevelListWithRouter = withRouter( toLevel(id: number) { const maxLevel = Math.max(...this.props.user.levels); - if (maxLevel + 1 >= id) { + if ((maxLevel === -Infinity || maxLevel === +Infinity) || maxLevel + 1 >= id) { this.props.history.push(`/level/${id}`); } else { this.props.setSnackbar(true);