cvs: bugtracker /includes bug.php
| From: | Barry Carlyon | Date: | Thu, 14 Aug 2008 09:11:59 +0000 |
| Subject: | cvs: bugtracker /includes bug.php | ||
| Groups: | php.webmaster | ||
| Request: | Send a blank email to php-webmaster+get-2417@lists.php.net to get a copy of this message | ||
bcarlyon Thu Aug 14 09:11:59 2008 UTC
Modified files:
/bugtracker/includes bug.php
Log:
Stop multiple emails if the assigned and reportee and the same person
http://cvs.php.net/viewvc.cgi/bugtracker/includes/bug.php?r1=1.20&r2=1.21&diff_format=u
Index: bugtracker/includes/bug.php
diff -u bugtracker/includes/bug.php:1.20 bugtracker/includes/bug.php:1.21
--- bugtracker/includes/bug.php:1.20 Thu Aug 14 09:06:48 2008
+++ bugtracker/includes/bug.php Thu Aug 14 09:11:59 2008
@@ -38,7 +38,7 @@
* @author Barry Carlyon <bcarlyon@php.net>
* @copyright 2008-2008 Barry Carlyon
* @license http://www.opensource.org/licenses/bsd-license.php
BSD License
-* @version CVS: $Id: bug.php,v 1.20 2008/08/14 09:06:48 bcarlyon Exp $
+* @version CVS: $Id: bug.php,v 1.21 2008/08/14 09:11:59 bcarlyon Exp $
* @link http://gsoc.barrycarlyon.servegame.org/
*/
@@ -147,7 +147,9 @@
//email the reportee
$email->send_to_user($this->bug_data['reported_by'], 'Bug Update; #' .
$this->bug_id, $email_message);
//email the assigned
- $email->send_to_user($target, 'Bug Assinged: #' . $this->bug_id, $email_message
. "\n\r\n\r" . 'AKA assinged to you!');
+ if ($target != $this->bug_data['reported_by']) {
+ $email->send_to_user($target, 'Bug Assinged: #' . $this->bug_id, $email_message
. "\n\r\n\r" . 'AKA assinged to you!');
+ }
//email the subscribed
return TRUE;
}
@@ -181,7 +183,7 @@
$email->send_to_user($this->bug_data['reported_by'], 'PHP Bug Updated:
#' . $this->bug_id, $email_message);
trace('send to reported');
- if (!empty($this->bug_data['assigned_to'])) {
+ if ($this->bug_data['assigned_to'] != $this->bug_data['repoted_by'])
{
trace('send to assigned');
$email->send_to_user($this->bug_data['assigned_to'], 'PHP Bug Updated:
#' . $this->bug_id, $email_message);
}