debug option to print curl requests
[shpub.git] / src / shpub / Command / Reply.php
index cb09ba77943e33231171523df6b73ca923b0f70b..327111dbcc6a345eb14b7f875af654d58f14fbb8 100644 (file)
@@ -4,13 +4,13 @@ namespace shpub;
 class Command_Reply
 {
     /**
-     * @var Config_Host
+     * @var Config
      */
-    protected $host;
+    protected $cfg;
 
-    public function __construct($host)
+    public function __construct($cfg)
     {
-        $this->host = $host;
+        $this->cfg = $cfg;
     }
 
     public function run($url, $text)
@@ -28,7 +28,7 @@ class Command_Reply
             ]
         );
 
-        $req = new Request($this->host);
+        $req = new Request($this->cfg->host, $this->cfg);
         $res = $req->send($body);
         $postUrl = $res->getHeader('Location');
         echo "Reply created at server\n";