Breaking: #96935 - Register linkvalidator linktypes via service configuration¶
See forge#96935
Description¶
Linkvalidator linktypes
are now registered via service configuration, also see
feature changelog.
Therefore the registration via
$GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['linkvalidator']['checkLinks']
has been removed.
Additionally, to be able to use autoconfiguration, the linktype
identifier
has to be provided by the service directly using the getIdentifier()
method, which is now required by the LinktypeInterface
.
In case a custom linktype
extends
\TYPO3\CMS\Linkvalidator\Linktype\AbstractLinktype
,
only the class property $identifier
has to be set, e.g.
protected string $identifier = 'my_linktype';
.
Impact¶
Registration of custom linktypes
via
$GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['linkvalidator']['checkLinks']
is not evaluated anymore.
The LinktypeInterface
is extended for
public function getIdentifier(): string
.
Affected Installations¶
All TYPO3 installations using the old registration.
All TYPO3 installations with custom linktypes
, not implementing
public function getIdentifier(): string
.
Migration¶
Remove $GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['linkvalidator']['checkLinks']
from your ext_localconf.php
file.
If autoconfigure
is not enabled in your Configuration/Services.(yaml|php)
,
add the tag linkvalidator.linktype
manually to your linktype
service.
Vendor\Extension\Linktype\MyCustomLinktype:
tags:
- name: linkvalidator.linktype
Additionally, make sure to either implement
public function getIdentifier(): string
or, in case your linktype
extends
AbstractLinktype
, to set the $identifier
class property.