From kronolith Fri Apr 02 11:58:26 2004 From: "W. Tasin" Date: Fri, 02 Apr 2004 11:58:26 +0000 To: kronolith Subject: [kronolith] CVS patch: don't send reminder if there was no mail Message-Id: <406D5562.5040102 () fhm ! edu> X-MARC-Message: https://marc.info/?l=kronolith&m=108090715408187 MIME-Version: 1 Content-Type: multipart/mixed; boundary="--------------080307060306040605050101" This is a multi-part message in MIME format. --------------080307060306040605050101 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Hi, here's another patch concerning the reminder stuff. This one prevents reminder.php mailing to "@localhost". Ciao Walter -- oohhh sveglia.... il mondo e' ammalato, ma x colpa di chi......... (Zucchero) :-------W._Tasin,_FB_04,_FHM-------------------PGP-KeyID:0x7961A645---: --------------080307060306040605050101 Content-Type: text/plain; name="kronolith.diff" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="kronolith.diff" --- /home/tasin/horde/CVS-HORDE/horde/kronolith/lib/Scheduler/kronolith.php Thu Mar 4 05:17:44 2004 +++ kronolith/lib/Scheduler/kronolith.php Fri Apr 2 13:43:25 2004 @@ -140,6 +140,14 @@ $mime->addPart($body); $msg_headers->addMIMEHeaders($mime); + + if (empty($recipients)) { + Horde::logMessage(sprintf('Cannot get a mail address for sending reminder %s to recipient(s): %s %s', $event->title, implode(', ', $users), implode(', ', $groups)), __FILE__, __LINE__, PEAR_LOG_ERR); + return; + + } else { + Horde::logMessage(sprintf('Sending reminder %s to %s', $event->title, implode(', ', $recipients)), __FILE__, __LINE__, PEAR_LOG_DEBUG); + } return $mime->send(implode(', ', $recipients), $msg_headers); } --------------080307060306040605050101 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline -- Kronolith mailing list - Join the hunt: http://horde.org/bounties/#kronolith Frequently Asked Questions: http://horde.org/faq/ To unsubscribe, mail: kronolith-unsubscribe@lists.horde.org --------------080307060306040605050101--