Skip to content

Commit

Permalink
[BUGFIX] Fix undefined index in ContentObjectRenderer
Browse files Browse the repository at this point in the history
Like the surrounding $conf['max'], this array index access should also
be secured.

Releases: main, 11.5
Resolves: #97908
Change-Id: I36ad5cf3d9eac5655e8721c8913bed43ab26377f
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/75134
Tested-by: core-ci <typo3@b13.com>
Tested-by: Oliver Bartsch <bo@cedev.de>
Reviewed-by: Oliver Bartsch <bo@cedev.de>
  • Loading branch information
Daniel authored and o-ba committed Jul 12, 2022
1 parent e5b93ae commit b3697e5
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -6046,7 +6046,7 @@ public function getQuery($table, $conf, $returnQueryArray = false)
$error = false;
if (($conf['max'] ?? false) || ($conf['begin'] ?? false)) {
// Finding the total number of records, if used:
if (str_contains(strtolower(($conf['begin'] ?? '') . $conf['max']), 'total')) {
if (str_contains(strtolower(($conf['begin'] ?? '') . ($conf['max'] ?? '')), 'total')) {
$countQueryBuilder = GeneralUtility::makeInstance(ConnectionPool::class)->getQueryBuilderForTable($table);
$countQueryBuilder->getRestrictions()->removeAll();
$countQueryBuilder->count('*')
Expand Down

0 comments on commit b3697e5

Please sign in to comment.