From afee192d2a77afa1c11d25156d0a44df94e19aed Mon Sep 17 00:00:00 2001 From: A. Täffner <darkalex@firesplash.de> Date: Sat, 23 Jan 2016 07:30:37 -0500 Subject: [PATCH] fixed the cronjob and noticed a bug in ISPC but not able to report as FlySpray is offline --- server/plugins-available/maildrop_plugin.inc.php | 18 +++++++++++++++--- 1 files changed, 15 insertions(+), 3 deletions(-) diff --git a/server/plugins-available/maildrop_plugin.inc.php b/server/plugins-available/maildrop_plugin.inc.php index 73bace8..5e05bc3 100644 --- a/server/plugins-available/maildrop_plugin.inc.php +++ b/server/plugins-available/maildrop_plugin.inc.php @@ -137,7 +137,11 @@ } // Load the master template - $tpl = file_get_contents($conf["rootpath"].'/conf/autoresponder.master'); + if(file_exists($conf["rootpath"].'/conf-custom/autoresponder.master')) { + $tpl = file_get_contents($conf["rootpath"].'/conf-custom/autoresponder.master'); + } else { + $tpl = file_get_contents($conf["rootpath"].'/conf/autoresponder.master'); + } $tpl = str_replace('{vmail_mailbox_base}', $mail_config["homedir_path"], $tpl); if ($data["new"]["autoresponder_start_date"] != '0000-00-00 00:00:00') { // Dates have been set @@ -192,12 +196,20 @@ $mailfilter_content = ''; if($data["new"]["cc"] != '') { - $mailfilter_content .= "cc \"!".$data["new"]["cc"]."\"\n"; + $tmp_mails_arr = explode(',',$data["new"]["cc"]); + foreach($tmp_mails_arr as $address) { + if(trim($address) != '') $mailfilter_content .= "cc \"!".trim($address)."\"\n"; + } + //$mailfilter_content .= "cc \"!".$data["new"]["cc"]."\"\n"; $app->log("Added CC address ".$data["new"]["cc"].' to mailfilter file.', LOGLEVEL_DEBUG); } if($data["new"]["move_junk"] == 'y') { - $mailfilter_content .= file_get_contents($conf["rootpath"].'/conf/mailfilter_move_junk.master')."\n"; + if(file_exists($conf["rootpath"].'/conf-custom/mailfilter_move_junk.master')) { + $mailfilter_content .= file_get_contents($conf["rootpath"].'/conf-custom/mailfilter_move_junk.master')."\n"; + } else { + $mailfilter_content .= file_get_contents($conf["rootpath"].'/conf/mailfilter_move_junk.master')."\n"; + } } $mailfilter_content .= $data["new"]["custom_mailfilter"]; -- Gitblit v1.9.1