Closed neufeind closed 2 months ago
Thanks for the feedback. What version of doctrine/dbal
are you using? Since version 2.11.0, fetchOne
is available and fetch
is marked as deprecated: https://github.com/doctrine/dbal/blob/2.11.0/lib/Doctrine/DBAL/Driver/Mysqli/MysqliStatement.php#L326
TYPO3 10 works with 2.10.x but this version has no fetchOne
method.
I'will add a requirement in the composer.json for a higher doctrine/dbal
version.
Added requirement here: https://github.com/Leuchtfeuer/locate/commit/b2d7d7804b4004570a95c7bb53ae3160c6721427
@davkraid Sorry for the late reply. doctrine/dbal is 2.10.4 as shipped with TYPO3 v10.4.36 (non-composer, official download).
Still an issue with TYPO3 v10 LTS (non-composer). Could we use fetch() instead in EXT:locate? Or drop TYPO v10-support? Unfortunately it's not really possible to clain TYPO3 v10-support but only for composer-mode sigh
Replacing the two fetchOne()-calls worked here.
Unfortunately it is a bit complicated, because we have marked the version V11 for Locate for TYPO3 v10.4 and v11.5 as compatible. We ourselves only work with Composer mode and there are no problems here. You are of course right that TYPO3 without Composer mode comes with a non-matching Doctrine/DBAL version. We now see three possibilities here:
fetchOne
calls with the previous fetchColumn(0)
calls.
Call to undefined method Doctrine\DBAL\Driver\Mysqli\MysqliStatement::fetchOne() | Error thrown in file /var/www/html/typo3conf/ext/locate/Classes/Hook/OverrideIconOverlayHook.php in line 55
The reason is that MysqliStatement in 10.4.x does not (yet) have a function fetchOne(). But we could use fetch() instead, I guess?