[BUGFIX] Avoid $GLOBALS['TYPO3_REQUEST'] warning in Clipboard
Functional test ext:felogin ContentVisibleFieldsTest::loginFormContainsExpectedFields indirectly calls $GLOBALS['TYPO3_REQUEST'] of Clipboard::initializeClipboard(). Clipboard class does multiple things: It is a 'repository' to find out which items are in the clipboard, and it helps with rendering. The 'repository' part does not need $request. Functional tests call initializeClipboard() without handing over a request object and without preparing a request as $GLOBALS['TYPO3_REQUEST']. While they could actively init a request, they shouldn't need to do so. The patch adds a fallback so clipboard class does not emit a warning if neither $request is given nor $GLOBALS['TYPO3_REQUEST'] is set. An according @todo is added to further streamline the code. Change-Id: Ifde4e8fa053203acf8570cf969b073a7da176c42 Resolves: #95509 Releases: master Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/71477 Tested-by:Stefan Bürk <stefan@buerk.tech> Tested-by:
core-ci <typo3@b13.com> Tested-by:
Benjamin Franzke <bfr@qbus.de> Reviewed-by:
Stefan Bürk <stefan@buerk.tech> Reviewed-by:
Benjamin Franzke <bfr@qbus.de>
Please register or sign in to comment