XF 2.1 Can't logout because deprecated function Redis::delete()

developr

Active member
Dear Community,

I get this error when I try to logout.

Code:
ErrorException: [E_DEPRECATED] Function Redis::delete() is deprecated in src/vendor/doctrine/cache/lib/Doctrine/Common/Cache/RedisCache.php at line 135
XF::handlePhpError() in src/vendor/doctrine/cache/lib/Doctrine/Common/Cache/RedisCache.php at line 135
Doctrine\Common\Cache\RedisCache->doDelete() in src/vendor/doctrine/cache/lib/Doctrine/Common/Cache/CacheProvider.php at line 140
Doctrine\Common\Cache\CacheProvider->delete() in src/XF/Session/CacheStorage.php at line 29
XF\Session\CacheStorage->deleteSession() in src/XF/Session/Session.php at line 225
XF\Session\Session->expunge() in src/XF/Session/Session.php at line 245
XF\Session\Session->regenerate() in src/XF/Session/Session.php at line 275
XF\Session\Session->logoutUser() in src/XF/ControllerPlugin/Login.php at line 255
XF\ControllerPlugin\Login->logoutVisitor() in src/addons/SV/SignupAbuseBlocking/XF/ControllerPlugin/Login.php at line 50
SV\SignupAbuseBlocking\XF\ControllerPlugin\Login->logoutVisitor() in src/XF/Pub/Controller/Logout.php at line 21
XF\Pub\Controller\Logout->actionIndex() in src/XF/Mvc/Dispatcher.php at line 321
XF\Mvc\Dispatcher->dispatchClass() in src/XF/Mvc/Dispatcher.php at line 248
XF\Mvc\Dispatcher->dispatchFromMatch() in src/XF/Mvc/Dispatcher.php at line 100
XF\Mvc\Dispatcher->dispatchLoop() in src/XF/Mvc/Dispatcher.php at line 50
XF\Mvc\Dispatcher->run() in src/XF/App.php at line 2177
XF\App->run() in src/XF.php at line 390
XF::runApp() in index.php at line 20

I use redis as a cache. here is my config.php

PHP:
$config['cache']['enabled'] = true;
$config['cache']['sessions'] = true;
$config['cache']['provider'] = 'Redis';
$config['cache']['config'] = [
    'directory' => '/srv/www/domain.tld/htdocs/internal_data/cache',
     'server' => '127.0.0.1',
     'host' => '127.0.0.1',
        'port' => 6379,
        'compress_data' => 6,
        'connect_retries' => 2,
        'use_lua' => true,
        'read_timeout' => 1,
        'timeout' => 1,
        'database' => 2,
        'serializer' => 'igbinary'
];

I use XF2.1.2, PHP 7.2.21-1 and Redis server v=4.0.9

How can I solve this problem?
 
Top