1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-05-06 07:35:29 +02:00

[ticket/8323] Comments

PHPBB3-8323
This commit is contained in:
Nathan Guse 2012-12-07 18:51:06 -06:00
parent 8e6a69bf0c
commit 4ab07aa45e
2 changed files with 16 additions and 7 deletions

View File

@ -1263,7 +1263,7 @@ function handle_message_list_actions(&$address_list, &$error, $remove_u, $remove
} }
$db->sql_freeresult($result); $db->sql_freeresult($result);
// print a notice about users not being added who do not want to receive pms // print a notice about users not being added who do not have permission to receive PMs
if ($removed) if ($removed)
{ {
$error[] = $user->lang['PM_USERS_REMOVED_NO_PERMISSION']; $error[] = $user->lang['PM_USERS_REMOVED_NO_PERMISSION'];

View File

@ -1553,12 +1553,21 @@ for ($i = 0, $end = sizeof($post_list); $i < $end; ++$i)
// Can this user receive a Private Message? // Can this user receive a Private Message?
$can_receive_pm = ( $can_receive_pm = (
$user_cache[$poster_id]['user_type'] != USER_IGNORE && // They must be a "normal" user // They must be a "normal" user
($user_cache[$poster_id]['user_type'] != USER_INACTIVE && $user_cache[$poster_id]['user_inactive_reason'] == INACTIVE_MANUAL) && // They must not be deactivated by the administrator $user_cache[$poster_id]['user_type'] != USER_IGNORE &&
in_array($poster_id, $can_receive_pm_list) && // They must be able to read PMs
!in_array($poster_id, $permanently_banned_users) && // They must not be permanently banned // They must not be deactivated by the administrator
(($auth->acl_gets('a_', 'm_') || $auth->acl_getf_global('m_')) || $data['user_allow_pm']) // They must allow users to contact via PM ($user_cache[$poster_id]['user_type'] != USER_INACTIVE && $user_cache[$poster_id]['user_inactive_reason'] == INACTIVE_MANUAL) &&
) ? true : false;
// They must be able to read PMs
in_array($poster_id, $can_receive_pm_list) &&
// They must not be permanently banned
!in_array($poster_id, $permanently_banned_users) &&
// They must allow users to contact via PM
(($auth->acl_gets('a_', 'm_') || $auth->acl_getf_global('m_')) || $data['user_allow_pm'])
);
// //
$post_row = array( $post_row = array(