feat : order
This commit is contained in:
@@ -64,7 +64,7 @@ class ConfigCache
|
||||
* @param $key
|
||||
* @param int $isRedis
|
||||
* @param int $expire
|
||||
* @return false|HigherOrderTapProxy|mixed|\Redis|string|null
|
||||
* @return false|HigherOrderTapProxy|mixed|\Redis|string
|
||||
* @throws ContainerExceptionInterface
|
||||
* @throws NotFoundExceptionInterface
|
||||
*/
|
||||
@@ -77,10 +77,10 @@ class ConfigCache
|
||||
if ($isRedis == 1) {
|
||||
$this->redis->setEx($redisKey, $value, $expire,RedisCode::SYSTEM_DB);
|
||||
}
|
||||
return $value;
|
||||
return $value ?? ConfigCode::DEFAULT_VALUE[$key];
|
||||
}
|
||||
|
||||
return $this->redis->get($key,RedisCode::SYSTEM_DB) ?? ConfigCode::DEFAULT_VALUE[$key];
|
||||
return $this->redis->get($redisKey,RedisCode::SYSTEM_DB) ?? ConfigCode::DEFAULT_VALUE[$key];
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user