Commit c31d3dfe authored by Dominik Hebeler's avatar Dominik Hebeler
Browse files

fixed cache error when no search engine is enabled

parent 764d596e
......@@ -676,7 +676,7 @@ class MetaGer
}
# Setting dummy engine as active if it exists (suma file created from example)
if($this->getFokus() === "web" && isset($this->sumaFile->sumas->{"dummy"})){
if ($this->getFokus() === "web" && isset($this->sumaFile->sumas->{"dummy"})) {
$this->enabledSearchengines["dummy"] = $this->sumaFile->sumas->{"dummy"};
}
......@@ -763,6 +763,10 @@ class MetaGer
foreach ($this->engines as $engine) {
$keys[] = $engine->hash;
}
# Noch searchengines enabled
if (empty($keys)) {
return;
}
$cacheValues = Cache::many($keys);
foreach ($this->engines as $engine) {
if ($cacheValues[$engine->hash] !== null) {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment