summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Gohr <andi@splitbrain.org>2008-10-12 23:28:26 +0200
committerAndreas Gohr <andi@splitbrain.org>2008-10-12 23:28:26 +0200
commit55eea442360b84450c3b7618fafaba3f75885294 (patch)
tree4b3a1bb12c74b0c3fec5e136cb6ca028a32034cb
parent37a1dc12655862a2f6e02b06145bd31a2f8b5489 (diff)
downloadrpg-55eea442360b84450c3b7618fafaba3f75885294.tar.gz
rpg-55eea442360b84450c3b7618fafaba3f75885294.tar.bz2
don't send subscriber mails to the editor herself FS#1450
darcs-hash:20081012212826-7ad00-0027ac926fdaa413521704536465bb83938a4366.gz
-rw-r--r--inc/common.php7
1 files changed, 5 insertions, 2 deletions
diff --git a/inc/common.php b/inc/common.php
index 27b5663b9..73e153947 100644
--- a/inc/common.php
+++ b/inc/common.php
@@ -1024,7 +1024,7 @@ function notify($id,$who,$rev='',$summary='',$minor=false,$replace=array()){
}elseif($who == 'subscribers'){
if(!$conf['subscribers']) return; //subscribers enabled?
if($conf['useacl'] && $_SERVER['REMOTE_USER'] && $minor) return; //skip minors
- $bcc = subscriber_addresslist($id);
+ $bcc = subscriber_addresslist($id,false);
if(empty($bcc)) return;
$to = '';
$text = rawLocale('subscribermail');
@@ -1203,7 +1203,7 @@ function is_subscribed($id,$uid,$ns=false){
*
* @author Steven Danz <steven-danz@kc.rr.com>
*/
-function subscriber_addresslist($id){
+function subscriber_addresslist($id,$self=true){
global $conf;
global $auth;
@@ -1219,6 +1219,7 @@ function subscriber_addresslist($id){
$mlist = file($file);
foreach ($mlist as $who) {
$who = rtrim($who);
+ if(!$self && $who == $_SERVER['REMOTE_USER']) continue;
$users[$who] = true;
}
}
@@ -1231,6 +1232,7 @@ function subscriber_addresslist($id){
$mlist = file($nsfile);
foreach ($mlist as $who) {
$who = rtrim($who);
+ if(!$self && $who == $_SERVER['REMOTE_USER']) continue;
$users[$who] = true;
}
}
@@ -1242,6 +1244,7 @@ function subscriber_addresslist($id){
$mlist = file($nsfile);
foreach ($mlist as $who) {
$who = rtrim($who);
+ if(!$self && $who == $_SERVER['REMOTE_USER']) continue;
$users[$who] = true;
}
}