[Bridge] Simplify cache loading
This commit is contained in:
parent
85a025a82b
commit
cd9435b936
1 changed files with 4 additions and 7 deletions
|
@ -251,14 +251,11 @@ abstract class BridgeAbstract implements BridgeInterface {
|
|||
if(!is_null($this->cache)){
|
||||
$this->cache->prepare($inputs);
|
||||
$time = $this->cache->getTime();
|
||||
} else {
|
||||
$time = false;
|
||||
}
|
||||
|
||||
if($time !== false && (time() - $this->getCacheDuration() < $time)){
|
||||
$this->items = $this->cache->loadData();
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
if(empty($this->parameters)){
|
||||
if(!empty($inputs)){
|
||||
|
|
Loading…
Reference in a new issue