|
@@ 913-914 (lines=2) @@
|
| 910 |
|
// Goodness, this is fun. We need to validate the action. |
| 911 |
|
elseif ($_REQUEST['actions'][$row['id_topic']] == 'sticky' && !in_array(0, $boards_can['make_sticky']) && !in_array($row['id_board'], $boards_can['make_sticky'])) |
| 912 |
|
unset($_REQUEST['actions'][$row['id_topic']]); |
| 913 |
|
elseif ($_REQUEST['actions'][$row['id_topic']] == 'move' && !in_array(0, $boards_can['move_any']) && !in_array($row['id_board'], $boards_can['move_any']) && ($row['id_member_started'] != $user_info['id'] || (!in_array(0, $boards_can['move_own']) && !in_array($row['id_board'], $boards_can['move_own'])))) |
| 914 |
|
unset($_REQUEST['actions'][$row['id_topic']]); |
| 915 |
|
elseif ($_REQUEST['actions'][$row['id_topic']] == 'remove' && !in_array(0, $boards_can['remove_any']) && !in_array($row['id_board'], $boards_can['remove_any']) && ($row['id_member_started'] != $user_info['id'] || (!in_array(0, $boards_can['remove_own']) && !in_array($row['id_board'], $boards_can['remove_own'])))) |
| 916 |
|
unset($_REQUEST['actions'][$row['id_topic']]); |
| 917 |
|
// @todo $locked is not set, what are you trying to do? (taking the change it is supposed to be $row['locked']) |
|
@@ 915-916 (lines=2) @@
|
| 912 |
|
unset($_REQUEST['actions'][$row['id_topic']]); |
| 913 |
|
elseif ($_REQUEST['actions'][$row['id_topic']] == 'move' && !in_array(0, $boards_can['move_any']) && !in_array($row['id_board'], $boards_can['move_any']) && ($row['id_member_started'] != $user_info['id'] || (!in_array(0, $boards_can['move_own']) && !in_array($row['id_board'], $boards_can['move_own'])))) |
| 914 |
|
unset($_REQUEST['actions'][$row['id_topic']]); |
| 915 |
|
elseif ($_REQUEST['actions'][$row['id_topic']] == 'remove' && !in_array(0, $boards_can['remove_any']) && !in_array($row['id_board'], $boards_can['remove_any']) && ($row['id_member_started'] != $user_info['id'] || (!in_array(0, $boards_can['remove_own']) && !in_array($row['id_board'], $boards_can['remove_own'])))) |
| 916 |
|
unset($_REQUEST['actions'][$row['id_topic']]); |
| 917 |
|
// @todo $locked is not set, what are you trying to do? (taking the change it is supposed to be $row['locked']) |
| 918 |
|
elseif ($_REQUEST['actions'][$row['id_topic']] == 'lock' && !in_array(0, $boards_can['lock_any']) && !in_array($row['id_board'], $boards_can['lock_any']) && ($row['id_member_started'] != $user_info['id'] || $row['locked'] == 1 || (!in_array(0, $boards_can['lock_own']) && !in_array($row['id_board'], $boards_can['lock_own'])))) |
| 919 |
|
unset($_REQUEST['actions'][$row['id_topic']]); |
|
@@ 918-919 (lines=2) @@
|
| 915 |
|
elseif ($_REQUEST['actions'][$row['id_topic']] == 'remove' && !in_array(0, $boards_can['remove_any']) && !in_array($row['id_board'], $boards_can['remove_any']) && ($row['id_member_started'] != $user_info['id'] || (!in_array(0, $boards_can['remove_own']) && !in_array($row['id_board'], $boards_can['remove_own'])))) |
| 916 |
|
unset($_REQUEST['actions'][$row['id_topic']]); |
| 917 |
|
// @todo $locked is not set, what are you trying to do? (taking the change it is supposed to be $row['locked']) |
| 918 |
|
elseif ($_REQUEST['actions'][$row['id_topic']] == 'lock' && !in_array(0, $boards_can['lock_any']) && !in_array($row['id_board'], $boards_can['lock_any']) && ($row['id_member_started'] != $user_info['id'] || $row['locked'] == 1 || (!in_array(0, $boards_can['lock_own']) && !in_array($row['id_board'], $boards_can['lock_own'])))) |
| 919 |
|
unset($_REQUEST['actions'][$row['id_topic']]); |
| 920 |
|
// If the topic is approved then you need permission to approve the posts within. |
| 921 |
|
elseif ($_REQUEST['actions'][$row['id_topic']] == 'approve' && (!$row['unapproved_posts'] || (!in_array(0, $boards_can['approve_posts']) && !in_array($row['id_board'], $boards_can['approve_posts'])))) |
| 922 |
|
unset($_REQUEST['actions'][$row['id_topic']]); |