diff options
author | Maat <maat-pub@mageia.biz> | 2020-05-08 21:52:11 +0200 |
---|---|---|
committer | Maat <maat-pub@mageia.biz> | 2020-05-08 21:52:11 +0200 |
commit | 8ea437e30605e0f66b5220bf904a61d7c1d11ddd (patch) | |
tree | e0db2bb4a012d5b06a633160b19f62f4868ecd28 /phpBB/develop/add_permissions.php | |
parent | 36bc1870f21fac04736a1049c1d5b8e127d729f4 (diff) | |
parent | 2fdd46b36431ae0f58bb2e78e42553168db9a0ff (diff) | |
download | forums-8ea437e30605e0f66b5220bf904a61d7c1d11ddd.tar forums-8ea437e30605e0f66b5220bf904a61d7c1d11ddd.tar.gz forums-8ea437e30605e0f66b5220bf904a61d7c1d11ddd.tar.bz2 forums-8ea437e30605e0f66b5220bf904a61d7c1d11ddd.tar.xz forums-8ea437e30605e0f66b5220bf904a61d7c1d11ddd.zip |
Merge remote-tracking branch 'upstream/prep-release-3.2.9'
Diffstat (limited to 'phpBB/develop/add_permissions.php')
-rw-r--r-- | phpBB/develop/add_permissions.php | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/phpBB/develop/add_permissions.php b/phpBB/develop/add_permissions.php index a5279f8f13..ee5e116d91 100644 --- a/phpBB/develop/add_permissions.php +++ b/phpBB/develop/add_permissions.php @@ -64,6 +64,7 @@ $f_permissions = array( 'f_vote' => array(1, 0), 'f_votechg' => array(1, 0), 'f_announce'=> array(1, 0), + 'f_announce_global' => array(1, 0), 'f_sticky' => array(1, 0), 'f_attach' => array(1, 0), 'f_download'=> array(1, 0), @@ -155,6 +156,7 @@ $u_permissions = array( 'u_download' => array(0, 1), 'u_attach' => array(0, 1), 'u_sig' => array(0, 1), + 'u_emoji' => array(0, 1), 'u_pm_attach' => array(0, 1), 'u_pm_bbcode' => array(0, 1), 'u_pm_smilies' => array(0, 1), @@ -184,7 +186,7 @@ while ($row = $db->sql_fetchrow($result)) } $db->sql_freeresult($result); -if (sizeof($remove_auth_options)) +if (count($remove_auth_options)) { $db->sql_query('DELETE FROM ' . ACL_USERS_TABLE . ' WHERE auth_option_id IN (' . implode(', ', $remove_auth_options) . ')'); $db->sql_query('DELETE FROM ' . ACL_GROUPS_TABLE . ' WHERE auth_option_id IN (' . implode(', ', $remove_auth_options) . ')'); @@ -198,7 +200,7 @@ $prefixes = array('f_', 'a_', 'm_', 'u_'); foreach ($prefixes as $prefix) { $var = $prefix . 'permissions'; - if (sizeof(${$var})) + if (count(${$var})) { foreach (${$var} as $auth_option => $l_ary) { @@ -378,8 +380,6 @@ function mass_auth($ug_type, $forum_id, $ug_id, $acl_list, $setting) $sql = 'VALUES ' . implode(', ', preg_replace('#^(.*?)$#', '(\1)', $sql_subary)); break; - case 'mssql': - case 'sqlite': case 'sqlite3': $sql = implode(' UNION ALL ', preg_replace('#^(.*?)$#', 'SELECT \1', $sql_subary)); break; @@ -388,7 +388,7 @@ function mass_auth($ug_type, $forum_id, $ug_id, $acl_list, $setting) foreach ($sql_subary as $sql) { $sql = "INSERT INTO $table ($id_field, forum_id, auth_option_id, auth_setting) VALUES ($sql)"; - $result = $db->sql_query($sql); + $db->sql_query($sql); $sql = ''; } } @@ -396,7 +396,7 @@ function mass_auth($ug_type, $forum_id, $ug_id, $acl_list, $setting) if ($sql != '') { $sql = "INSERT INTO $table ($id_field, forum_id, auth_option_id, auth_setting) $sql"; - $result = $db->sql_query($sql); + $db->sql_query($sql); } break; @@ -404,7 +404,7 @@ function mass_auth($ug_type, $forum_id, $ug_id, $acl_list, $setting) case 'delete': foreach ($sql_subary as $sql) { - $result = $db->sql_query($sql); + $db->sql_query($sql); $sql = ''; } break; |