From f9a7ea862fbff836fa32e62f66a7e12aab573b49 Mon Sep 17 00:00:00 2001
From: Davide Aprea <davide@suma-ev.de>
Date: Mon, 23 Nov 2020 15:37:22 +0100
Subject: [PATCH] add dummy engine to create search engines function

---
 app/MetaGer.php | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/app/MetaGer.php b/app/MetaGer.php
index a86d7f26b..5a7109490 100644
--- a/app/MetaGer.php
+++ b/app/MetaGer.php
@@ -675,6 +675,11 @@ class MetaGer
             $this->enabledSearchengines["bing"] = $this->sumaFile->sumas->{"bing"};
         }
 
+        # Setting dummy engine as active if it exists (suma file created from example)
+        if($this->getFokus() === "web" && isset($this->sumaFile->sumas->{"dummy"})){
+            $this->enabledSearchengines["dummy"] = $this->sumaFile->sumas->{"dummy"};
+        }
+
         if (sizeof($this->enabledSearchengines) === 0) {
             $filter = "";
             foreach ($this->queryFilter as $queryFilter => $filterPhrase) {
-- 
GitLab