Skip to content
Snippets Groups Projects
Commit 484716a3 authored by Dominik Hebeler's avatar Dominik Hebeler
Browse files

Merge branch '56-falsche-fehlermeldung' into 'master'

Der Zähler für die aktivierten Suchmaschinen sollte nun korrekt funktionieren

Closes #56

See merge request !62
parents a1377d56 51d66948
No related branches found
No related tags found
2 merge requests!73Updates from Master,!62Der Zähler für die aktivierten Suchmaschinen sollte nun korrekt funktionieren
...@@ -223,7 +223,7 @@ class MetaGer ...@@ -223,7 +223,7 @@ class MetaGer
$xml = simplexml_load_file($this->sumaFile); $xml = simplexml_load_file($this->sumaFile);
$enabledSearchengines = []; $enabledSearchengines = [];
$overtureEnabled = FALSE; $overtureEnabled = FALSE;
$countSumas = 0;
if($this->fokus === "angepasst") if($this->fokus === "angepasst")
{ {
$sumas = $xml->xpath("suma"); $sumas = $xml->xpath("suma");
...@@ -254,7 +254,8 @@ class MetaGer ...@@ -254,7 +254,8 @@ class MetaGer
{ {
$overtureEnabled = TRUE; $overtureEnabled = TRUE;
} }
if( $suma["name"]->__toString() !== "qualigo" && $suma["name"]->__toString() !== "similar_product_ads" && $suma["name"]->__toString() !== "overtureAds" )
$countSumas += 1;
$enabledSearchengines[] = $suma; $enabledSearchengines[] = $suma;
} }
} }
...@@ -277,13 +278,15 @@ class MetaGer ...@@ -277,13 +278,15 @@ class MetaGer
{ {
$overtureEnabled = TRUE; $overtureEnabled = TRUE;
} }
if( $suma["name"]->__toString() !== "qualigo" && $suma["name"]->__toString() !== "similar_product_ads" && $suma["name"]->__toString() !== "overtureAds" )
$countSumas += 1;
$enabledSearchengines[] = $suma; $enabledSearchengines[] = $suma;
} }
} }
} }
} }
if( ( $this->fokus !== "bilder" && sizeof($enabledSearchengines) <= 3 ) || ( $this->fokus === "bilder" && sizeof($enabledSearchengines) === 0) ) if( ( $this->fokus !== "bilder" && $countSumas <= 0 ) || ( $this->fokus === "bilder" && sizeof($enabledSearchengines) === 0) )
{ {
$this->errors[] = "Achtung: Sie haben in ihren Einstellungen keine Suchmaschine ausgewählt."; $this->errors[] = "Achtung: Sie haben in ihren Einstellungen keine Suchmaschine ausgewählt.";
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment