NotifySend.php
authorAlan Knowles <alan@roojs.com>
Thu, 30 Oct 2014 04:26:02 +0000 (12:26 +0800)
committerAlan Knowles <alan@roojs.com>
Thu, 30 Oct 2014 04:26:02 +0000 (12:26 +0800)
NotifySend.php

index 132c78e..83a60ed 100644 (file)
@@ -327,7 +327,7 @@ class Pman_Core_NotifySend extends Pman
             if (!isset($ff->Mail['helo'])) {
                 die("config Mail[helo] is not set");
             }
-            $debug_str = '';
+            $this->debug_str = '';
             $this->debug("Trying SMTP: $dom / HELO {$ff->Mail['helo']}");
             $mailer = Mail::factory('smtp', array(
                     'host'    => $dom ,
@@ -513,4 +513,11 @@ class Pman_Core_NotifySend extends Pman
     {
         die("done\n");
     }
+    var $debug_str = '';
+    
+    function debugHandler ($smtp, $message)
+    {
+        $this->debug_str .= strlen($this->debug_str) ? "\n" : '';
+        $this->debug_str .= $message;
+    }
 }
\ No newline at end of file