diff options
author | Marc Alexander <admin@m-a-styles.de> | 2014-08-07 17:57:00 +0200 |
---|---|---|
committer | Marc Alexander <admin@m-a-styles.de> | 2014-08-07 23:10:14 +0200 |
commit | 98c98e52ebf138e23e8fe85d8d2be54aa1f0144a (patch) | |
tree | 33188f64d26d8599dacd7b946282db2c7726f547 | |
parent | a8dee3fb65fbc16115634715da3a8eff2bbbce04 (diff) | |
download | forums-98c98e52ebf138e23e8fe85d8d2be54aa1f0144a.tar forums-98c98e52ebf138e23e8fe85d8d2be54aa1f0144a.tar.gz forums-98c98e52ebf138e23e8fe85d8d2be54aa1f0144a.tar.bz2 forums-98c98e52ebf138e23e8fe85d8d2be54aa1f0144a.tar.xz forums-98c98e52ebf138e23e8fe85d8d2be54aa1f0144a.zip |
[ticket/12886] Remove obsolete check for f_user_lock
The user shouldn't be able to unlock his own topic if he doesn't have m_lock
permissions. Also, the check for f_user_lock was never going to evaluate to
true due to the topic not being unlocked making it obsolete anyway.
PHPBB3-12886
-rw-r--r-- | phpBB/viewtopic.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/phpBB/viewtopic.php b/phpBB/viewtopic.php index 1fdce5a6c3..50481302e6 100644 --- a/phpBB/viewtopic.php +++ b/phpBB/viewtopic.php @@ -539,8 +539,8 @@ $s_quickmod_action = append_sid( $quickmod_array = array( // 'key' => array('LANG_KEY', $userHasPermissions), - 'lock' => array('LOCK_TOPIC', ($topic_data['topic_status'] == ITEM_UNLOCKED) && ($auth->acl_get('m_lock', $forum_id) || ($auth->acl_get('f_user_lock', $forum_id) && $user->data['is_registered'] && $user->data['user_id'] == $topic_data['topic_poster'] && $topic_data['topic_status'] == ITEM_UNLOCKED))), - 'unlock' => array('UNLOCK_TOPIC', ($topic_data['topic_status'] != ITEM_UNLOCKED) && ($auth->acl_get('m_lock', $forum_id) || ($auth->acl_get('f_user_lock', $forum_id) && $user->data['is_registered'] && $user->data['user_id'] == $topic_data['topic_poster'] && $topic_data['topic_status'] == ITEM_UNLOCKED))), + 'lock' => array('LOCK_TOPIC', ($topic_data['topic_status'] == ITEM_UNLOCKED) && ($auth->acl_get('m_lock', $forum_id) || ($auth->acl_get('f_user_lock', $forum_id) && $user->data['is_registered'] && $user->data['user_id'] == $topic_data['topic_poster']))), + 'unlock' => array('UNLOCK_TOPIC', ($topic_data['topic_status'] != ITEM_UNLOCKED) && ($auth->acl_get('m_lock', $forum_id))), 'delete_topic' => array('DELETE_TOPIC', ($auth->acl_get('m_delete', $forum_id) || (($topic_data['topic_visibility'] != ITEM_DELETED) && $auth->acl_get('m_softdelete', $forum_id)))), 'restore_topic' => array('RESTORE_TOPIC', (($topic_data['topic_visibility'] == ITEM_DELETED) && $auth->acl_get('m_approve', $forum_id))), 'move' => array('MOVE_TOPIC', $auth->acl_get('m_move', $forum_id) && $topic_data['topic_status'] != ITEM_MOVED), |