public function Redis_Cache_PhpRedis::getLastFlushTime in Redis 7.3
File
- lib/
Redis/ Cache/ PhpRedis.php, line 23
Class
- Redis_Cache_PhpRedis
- Predis cache backend.
Code
public function getLastFlushTime() {
$client = $this
->getClient();
$key = $this
->getKey(self::LAST_FLUSH_KEY);
$values = $client
->hmget($key, array(
"permanent",
"volatile",
));
if (empty($values) || !is_array($values)) {
$ret = array(
0,
0,
);
}
else {
if (empty($values['permanent'])) {
$values['permanent'] = 0;
}
if (empty($values['volatile'])) {
$values['volatile'] = 0;
}
$ret = array(
$values['permanent'],
$values['volatile'],
);
}
return $ret;
}