Environment: localhost, Linux 64 bit.
Version: cloned and running from the GitHub 3.1.x branch (following the Area 51 wiki for Bug fixing the 3.1.x branch)
Database: postgreSQL, newly created from the repo install
I believe the problem is in includes/functions_posting.php, the section starting at line 1620:
Code: Select all
// This variable indicates if the user is able to post or put into the queue
$post_visibility = ITEM_APPROVED;
// Check the permissions for post approval.
// Moderators must go through post approval like ordinary users.
if (!$auth->acl_get('f_noapprove', $data['forum_id']))
{
// Post not approved, but in queue
$post_visibility = ITEM_UNAPPROVED;
switch ($post_mode)
{
case 'edit_first_post':
case 'edit':
case 'edit_last_post':
case 'edit_topic':
$post_visibility = ITEM_REAPPROVE;
break;
}
}
!$auth->acl_get('f_noapprove', $data['forum_id']
is always 0. I can not find anywhere in the code that modifies 'f_noapprove'.Forcing
$post_visibility = ITEM_REAPPROVE;
at this point appears to fix the problem. The post remains in the moderator queue, waiting for approve / disapprove. However, that is only one test case. I have tried several modifications, but cannot find a solution that works for all conditions.Permissions are very tricky and require a deep understanding to attempt modifications. I do not have this understanding.
Can someone please provide guidance for solving this problem?