Fix JSON HTML content sending, according to new tests
[shpub.git] / src / shpub / Config.php
index d41e45dc2a3495179fb797eb185d471a0b8e015f..2ca7d9adeea3c376196ebe0972fd313d53879ba0 100644 (file)
@@ -12,6 +12,8 @@ class Config
      */
     public $host;
 
+    public $debug = false;
+
     protected function getConfigFilePath()
     {
         if (!isset($_SERVER['HOME'])) {
@@ -86,7 +88,7 @@ class Config
         }
         foreach ($this->hosts as $key => $host) {
             if ($host->default) {
-                return $host;
+                return $key;
             }
         }
         
@@ -114,5 +116,10 @@ class Config
         }
         return '"' . $val . '"';
     }
+
+    public function setDebug($debug)
+    {
+        $this->debug = $debug;
+    }
 }
 ?>