Skip to content

Commit

Permalink
[BUGFIX] Use correct icon for pages table
Browse files Browse the repository at this point in the history
The check for content_from_pid is wrong as it is not the raw database record and therefore the relation is an array.

Resolves: #103405
Releases: main, 12.4
Change-Id: I31cfc584d9d1164ef96e1c3bec5ec75cc1619bd7
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/83662
Tested-by: Christian Kuhn <lolli@schwarzbu.ch>
Reviewed-by: Christian Kuhn <lolli@schwarzbu.ch>
Tested-by: core-ci <typo3@b13.com>
  • Loading branch information
georgringer authored and lolli42 committed Apr 8, 2024
1 parent 7d3c411 commit fba8c06
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion typo3/sysext/core/Classes/Imaging/IconFactory.php
Expand Up @@ -190,7 +190,8 @@ public function mapRecordTypeToIconIdentifier($table, array $row)
}
$recordType[4] = 'contains-' . $moduleSuffix;
}
if (($row['content_from_pid'] ?? 0) > 0) {
$contentFromPid = is_array($row['content_from_pid'] ?? 0) ? ($row['content_from_pid'][0]['uid'] ?? 0) : $row['content_from_pid'] ?? 0;
if ($contentFromPid > 0) {
if ($row['is_siteroot'] ?? false) {
$recordType[4] = $this->getRecordTypeForPageType(
$recordType[1],
Expand Down

0 comments on commit fba8c06

Please sign in to comment.