mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-25 19:38:53 +00:00
[ticket/17535] Fix Redis
PHPBB-17535
This commit is contained in:
parent
902c99bc0c
commit
833ed86283
2 changed files with 25 additions and 1 deletions
24
phpBB/phpbb/cache/driver/memory.php
vendored
24
phpBB/phpbb/cache/driver/memory.php
vendored
|
@ -45,6 +45,30 @@ abstract class memory extends \phpbb\cache\driver\base
|
|||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
function purge()
|
||||
{
|
||||
unset($this->vars);
|
||||
unset($this->sql_rowset);
|
||||
unset($this->sql_row_pointer);
|
||||
|
||||
if (function_exists('opcache_reset'))
|
||||
{
|
||||
@opcache_reset();
|
||||
}
|
||||
|
||||
$this->vars = [];
|
||||
$this->sql_rowset = [];
|
||||
$this->sql_row_pointer = [];
|
||||
|
||||
$this->is_modified = true;
|
||||
|
||||
// We save here to let the following cache hits succeed
|
||||
$this->save();
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
|
|
2
phpBB/phpbb/cache/driver/redis.php
vendored
2
phpBB/phpbb/cache/driver/redis.php
vendored
|
@ -141,7 +141,7 @@ class redis extends \phpbb\cache\driver\memory
|
|||
*/
|
||||
protected function _delete(string $var): bool
|
||||
{
|
||||
if ($this->redis->delete($var) > 0)
|
||||
if ($this->redis->del($var) > 0)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue