Commit bbac6e8f authored by Thomas Hohn's avatar Thomas Hohn Committed by Oliver Hader
Browse files

[BUGFIX] Avoid live ID processing if EXT:version not loaded

DataHandler does not need to force "live ID" processing to
be enabled on RelationHandler when EXT:version is not loaded.

Avoiding this saves some semi-expensive operations inside
the RelationHandler class.

Resolves: #78998
Releases: master
Change-Id: If53cdd73db15352d6f4854a5aef4b407836cb6ce
Reviewed-on: https://review.typo3.org/50970


Reviewed-by: default avatarThomas Hohn <thomas@hohn.dk>
Tested-by: default avatarTYPO3com <no-reply@typo3.com>
Reviewed-by: Claus Due's avatarClaus Due <claus@phpmind.net>
Tested-by: default avatarThomas Hohn <thomas@hohn.dk>
Reviewed-by: Wouter Wolters's avatarWouter Wolters <typo3@wouterwolters.nl>
Tested-by: Wouter Wolters's avatarWouter Wolters <typo3@wouterwolters.nl>
Reviewed-by: Oliver Hader's avatarOliver Hader <oliver.hader@typo3.org>
Tested-by: Oliver Hader's avatarOliver Hader <oliver.hader@typo3.org>
parent ad8fd1a1
......@@ -40,6 +40,7 @@ use TYPO3\CMS\Core\Resource\ResourceFactory;
use TYPO3\CMS\Core\Service\OpcodeCacheService;
use TYPO3\CMS\Core\Type\Bitmask\Permission;
use TYPO3\CMS\Core\Utility\ArrayUtility;
use TYPO3\CMS\Core\Utility\ExtensionManagementUtility;
use TYPO3\CMS\Core\Utility\File\BasicFileUtility;
use TYPO3\CMS\Core\Utility\GeneralUtility;
use TYPO3\CMS\Core\Utility\MathUtility;
......@@ -9065,8 +9066,11 @@ class DataHandler
*/
protected function createRelationHandlerInstance()
{
$isVersionLoaded = ExtensionManagementUtility::isLoaded('version');
$relationHandler = GeneralUtility::makeInstance(RelationHandler::class);
$relationHandler->setWorkspaceId($this->BE_USER->workspace);
$relationHandler->setUseLiveReferenceIds($isVersionLoaded);
$relationHandler->setUseLiveParentIds($isVersionLoaded);
return $relationHandler;
}
......
Supports Markdown
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