[BUGFIX] Avoid unreliable 'rowCount()' in RedirectRepository
rowCount() on result sets for SELECT queries are not reliable across all dbmns, which doctrine/dbal comments in the docblock. See: https://github.com/doctrine/dbal/blob/110ab1387f11ca08dd510850d1f45bc6e79c74bb/src/Driver/Result.php#L77 Because of "rowCount()"'s unreliable behaviour for some dbms like sqlite, this should be avoided to ensure cross dbms support. This patch mitigate this with a simple COUNT() query replacement in '\TYPO3\CMS\Redirects\Repository\RedirectRepository' for the "ext:redirects", as this can be done without greater API changes. Other occurrences will be mitigated with dedicated patches and the proper suitable solution for the corresponding case. Resolves: #97455 Releases: main, 11.5 Change-Id: Ifbbe6e35e1854483d6102657d71f3b74e822dcf5 Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/74309 Tested-by:core-ci <typo3@b13.com> Tested-by:
Stefan Bürk <stefan@buerk.tech> Tested-by:
Oliver Bartsch <bo@cedev.de> Reviewed-by:
Stefan Bürk <stefan@buerk.tech> Reviewed-by:
Oliver Klee <typo3-coding@oliverklee.de> Reviewed-by:
Oliver Bartsch <bo@cedev.de>
Please register or sign in to comment