mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-03 23:37:39 +02:00
Merge branch '3.1.x' into 3.2.x
* 3.1.x: [ticket/13264] Link to post if user can view it [ticket/13264] Do not force approved state if post visibility is known
This commit is contained in:
@@ -1492,6 +1492,10 @@ function submit_post($mode, $subject, $username, $topic_type, &$poll_ary, &$data
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else if (isset($data['post_visibility']) && $data['post_visibility'] !== false)
|
||||||
|
{
|
||||||
|
$post_visibility = $data['post_visibility'];
|
||||||
|
}
|
||||||
|
|
||||||
// MODs/Extensions are able to force any visibility on posts
|
// MODs/Extensions are able to force any visibility on posts
|
||||||
if (isset($data_ary['force_approved_state']))
|
if (isset($data_ary['force_approved_state']))
|
||||||
@@ -2299,7 +2303,9 @@ function submit_post($mode, $subject, $username, $topic_type, &$poll_ary, &$data
|
|||||||
|
|
||||||
$params = $add_anchor = '';
|
$params = $add_anchor = '';
|
||||||
|
|
||||||
if ($post_visibility == ITEM_APPROVED)
|
if ($post_visibility == ITEM_APPROVED ||
|
||||||
|
($auth->acl_get('m_softdelete', $data['forum_id']) && $post_visibility == ITEM_DELETED) ||
|
||||||
|
($auth->acl_get('m_approve', $data['forum_id']) && in_array($post_visibility, array(ITEM_UNAPPROVED, ITEM_REAPPROVE))))
|
||||||
{
|
{
|
||||||
$params .= '&t=' . $data_ary['topic_id'];
|
$params .= '&t=' . $data_ary['topic_id'];
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user