Skip to content
Snippets Groups Projects
Commit 0cab8780 authored by Alexander Schnitzler's avatar Alexander Schnitzler Committed by Christian Kuhn
Browse files

[TASK] Fix phpstan checkFunctionArgumentTypes errors in ext:core Tree

This patch fixes incompatible type usage in function arguments
and is preparatory work for introducing native type hints and
strict mode in all core files.

Releases: master, 10.4
Resolves: #92261
Change-Id: I9fe2fc72a60e794a03663625ea7ec3e40984b04b
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/65660


Tested-by: default avatarTYPO3com <noreply@typo3.com>
Tested-by: default avatarDaniel Goerz <daniel.goerz@posteo.de>
Tested-by: default avatarOliver Bartsch <bo@cedev.de>
Tested-by: default avatarSascha Egerer <sascha@sascha-egerer.de>
Tested-by: default avatarChristian Kuhn <lolli@schwarzbu.ch>
Reviewed-by: default avatarDaniel Goerz <daniel.goerz@posteo.de>
Reviewed-by: default avatarOliver Klee <typo3-coding@oliverklee.de>
Reviewed-by: default avatarOliver Bartsch <bo@cedev.de>
Reviewed-by: default avatarSascha Egerer <sascha@sascha-egerer.de>
Reviewed-by: default avatarChristian Kuhn <lolli@schwarzbu.ch>
parent f8d2394d
Branches
Tags
No related merge requests found
......@@ -263,13 +263,13 @@ class DatabaseTreeDataProvider extends AbstractTableConfigurationTreeDataProvide
$node->setExpanded(true);
$node->setLabel($this->getLanguageService()->sL($GLOBALS['TCA'][$this->tableName]['ctrl']['title']));
} else {
$row = BackendUtility::getRecordWSOL($this->tableName, $basicNode->getId(), '*', '', false);
$row = BackendUtility::getRecordWSOL($this->tableName, (int)$basicNode->getId(), '*', '', false);
$node->setLabel(BackendUtility::getRecordTitle($this->tableName, $row) ?: $basicNode->getId());
$node->setSelected(GeneralUtility::inList($this->getSelectedList(), $basicNode->getId()));
$node->setExpanded($this->isExpanded($basicNode));
}
$node->setId($basicNode->getId());
$node->setSelectable(!GeneralUtility::inList($this->getNonSelectableLevelList(), $level) && !in_array($basicNode->getId(), $this->getItemUnselectableList()));
$node->setSelectable(!GeneralUtility::inList($this->getNonSelectableLevelList(), (string)$level) && !in_array($basicNode->getId(), $this->getItemUnselectableList()));
$node->setSortValue($this->nodeSortValues[$basicNode->getId()]);
$iconFactory = GeneralUtility::makeInstance(IconFactory::class);
$node->setIcon($iconFactory->getIconForRecord($this->tableName, $row, Icon::SIZE_SMALL));
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment