-
-
Notifications
You must be signed in to change notification settings - Fork 260
Open
Description
Describe the bug
If indexing is disabled for the mount page, the attempt to fetch solr site in ApacheSolrForTypo3\Solr\Domain\Index\Queue\RecordMonitor\Helper::addPageToMountingSiteIndexQueue
will return null and there will be an exception. A check is missing there.
protected function addPageToMountingSiteIndexQueue(int $mountedPageId, array $mountProperties): void
{
$siteRepository = GeneralUtility::makeInstance(SiteRepository::class);
$mountingSite = $siteRepository->getSiteByPageId($mountProperties['mountPageDestination']);
/** @var Page $pageInitializer */
$pageInitializer = GeneralUtility::makeInstance(Page::class);
$pageInitializer->setSite($mountingSite);
Here $mountingSite
will be null and it is correct if indexing is disabled for the mount point, but
setSite` expects a valis site.
To Reproduce
Steps to reproduce the behavior:
- Create a new root page, which is a mount point to the existing root page.
- Disable indexing via
solr_enabled_read: false
in the site config for that new site - Edit any page in the site -> exception
Used versions (please complete the following information):
- TYPO3 Version: 12.4.28
- EXT:solr Version: 12.0.1
Metadata
Metadata
Assignees
Labels
No labels