-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Avoid fatal error in match table generation (#101)
- Loading branch information
Showing
2 changed files
with
8 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,7 +5,7 @@ | |
/*************************************************************** | ||
* Copyright notice | ||
* | ||
* (c) 2009-2021 Rene Nitzsche ([email protected]) | ||
* (c) 2009-2024 Rene Nitzsche ([email protected]) | ||
* All rights reserved | ||
* | ||
* This script is part of the TYPO3 project. The TYPO3 project is | ||
|
@@ -111,6 +111,10 @@ private function findKeyString($teams) | |
*/ | ||
private function createTable($teams, $table, $options) | ||
{ | ||
$ret = []; | ||
if (empty($teams)) { | ||
return $ret; | ||
} | ||
$option_halfseries = isset($options['halfseries']) ? intval($options['halfseries']) : 0; | ||
$option_nomatch = isset($options['nomatch']) ? intval($options['nomatch']) : 0; | ||
// Alle Elemente einen Indexplatz hochschieben, damit die Team-Nr stimmt. | ||
|
@@ -121,7 +125,6 @@ private function createTable($teams, $table, $options) | |
// Zählung des Spieltags | ||
$dayCnt = isset($options['firstmatchday']) ? intval($options['firstmatchday']) : 0; | ||
|
||
$ret = []; | ||
// die Hinrunde hinzufügen | ||
if (2 != $option_halfseries) { | ||
foreach ($table as $day => $matches) { | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters