mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-28 14:18:52 +00:00
Only send PM notification if the user wants to receive one
git-svn-id: file:///svn/phpbb/trunk@5084 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
parent
b57ccb8cb9
commit
e15083f451
1 changed files with 2 additions and 2 deletions
|
@ -1367,7 +1367,7 @@ function pm_notification($mode, $author, $recipients, $subject, $message)
|
||||||
|
|
||||||
$recipient_list = implode(', ', array_keys($recipients));
|
$recipient_list = implode(', ', array_keys($recipients));
|
||||||
|
|
||||||
$sql = 'SELECT user_id, username, user_email, user_lang, user_notify_type, user_jabber
|
$sql = 'SELECT user_id, username, user_email, user_lang, user_notify_pm, user_notify_type, user_jabber
|
||||||
FROM ' . USERS_TABLE . "
|
FROM ' . USERS_TABLE . "
|
||||||
WHERE user_id IN ($recipient_list)";
|
WHERE user_id IN ($recipient_list)";
|
||||||
$result = $db->sql_query($sql);
|
$result = $db->sql_query($sql);
|
||||||
|
@ -1375,7 +1375,7 @@ function pm_notification($mode, $author, $recipients, $subject, $message)
|
||||||
$msg_list_ary = array();
|
$msg_list_ary = array();
|
||||||
while ($row = $db->sql_fetchrow($result))
|
while ($row = $db->sql_fetchrow($result))
|
||||||
{
|
{
|
||||||
if (trim($row['user_email']))
|
if ($row['user_notify_pm'] == 1 && trim($row['user_email']))
|
||||||
{
|
{
|
||||||
$msg_list_ary[] = array(
|
$msg_list_ary[] = array(
|
||||||
'method' => $row['user_notify_type'],
|
'method' => $row['user_notify_type'],
|
||||||
|
|
Loading…
Add table
Reference in a new issue