Nextcloud not working php fatal error

Hello Nextcloud

I have had this docker running for a while and it recently stopped working. I have checked the database connection and works and the database is there. I get this error in the log:

PHP Fatal error: Declaration of Doctrine\DBAL\Driver\PDOConnection::query() must be compatible with PDO::query(string $query, ?int $fetchMode = null, mixed …$fetchModeArgs) in /config/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOConnection.php on line 70

Any ideas on how to solve this?

Best regards