Important: #110233 - Search query added to AfterPageTreeItemsPreparedEvent
See forge#110233
Description
The PSR-14 event
\TYPO3\,
dispatched by
\TYPO3\ after the
backend page tree items have been resolved and prepared, now carries the current
page tree search query explicitly, instead of requiring event listeners to
extract it themselves from GET parameters of the current PSR-7 request.
A new method
get has been added, returning the
search phrase used to filter the page tree, or
null
if no search is
currently active.
Note that the
$request
argument - and therefore the return value of
get - is now nullable as well, since the event can be
dispatched in contexts where no PSR-7 request instance is available in future.
Impact
Custom event listeners that read the page tree search phrase via
$event->get should be adapted to use
the new
$event->get method instead.
Listeners should furthermore no longer assume that
get always
returns an instance of
Server, since it may be
null
in future major versions.