From 4d827b5b994f5efa2ec79583a87facb01897727f Mon Sep 17 00:00:00 2001 From: Marc Alexander Date: Fri, 29 May 2015 16:56:24 +0200 Subject: [ticket/6466] Remove remnants of old code PHPBB3-6466 --- phpBB/includes/acp/auth.php | 26 ++++++-------------------- 1 file changed, 6 insertions(+), 20 deletions(-) (limited to 'phpBB/includes') diff --git a/phpBB/includes/acp/auth.php b/phpBB/includes/acp/auth.php index 0f149ca907..efb92685f6 100644 --- a/phpBB/includes/acp/auth.php +++ b/phpBB/includes/acp/auth.php @@ -470,16 +470,12 @@ class auth_admin extends \phpbb\auth\auth // Build role dropdown options $current_role_id = (isset($cur_roles[$ug_id][$forum_id])) ? $cur_roles[$ug_id][$forum_id] : 0; - $s_role_options = ''; - @reset($roles); while (list($role_id, $role_row) = each($roles)) { $role_description = (!empty($user->lang[$role_row['role_description']])) ? $user->lang[$role_row['role_description']] : nl2br($role_row['role_description']); $role_name = (!empty($user->lang[$role_row['role_name']])) ? $user->lang[$role_row['role_name']] : $role_row['role_name']; - $title = ($role_description) ? ' title="' . $role_description . '"' : ''; - $s_role_options .= ''; $template->assign_block_vars('role_options', array( 'ID' => $role_id, 'ROLE_NAME' => $role_name, @@ -488,11 +484,6 @@ class auth_admin extends \phpbb\auth\auth )); } - if ($s_role_options) - { - $s_role_options = '' . $s_role_options; - } - if (!$current_role_id && $mode != 'view') { $s_custom_permissions = false; @@ -513,7 +504,6 @@ class auth_admin extends \phpbb\auth\auth $template->assign_block_vars($tpl_pmask . '.' . $tpl_fmask, array( 'NAME' => $ug_names_ary[$ug_id], - 'S_ROLE_OPTIONS' => $s_role_options, 'UG_ID' => $ug_id, 'S_CUSTOM' => $s_custom_permissions, 'FORUM_ID' => $forum_id) @@ -562,21 +552,18 @@ class auth_admin extends \phpbb\auth\auth // Build role dropdown options $current_role_id = (isset($cur_roles[$ug_id][$forum_id])) ? $cur_roles[$ug_id][$forum_id] : 0; - $s_role_options = ''; - @reset($roles); while (list($role_id, $role_row) = each($roles)) { $role_description = (!empty($user->lang[$role_row['role_description']])) ? $user->lang[$role_row['role_description']] : nl2br($role_row['role_description']); $role_name = (!empty($user->lang[$role_row['role_name']])) ? $user->lang[$role_row['role_name']] : $role_row['role_name']; - $title = ($role_description) ? ' title="' . $role_description . '"' : ''; - $s_role_options .= ''; - } - - if ($s_role_options) - { - $s_role_options = '' . $s_role_options; + $template->assign_block_vars('role_options', array( + 'ID' => $role_id, + 'ROLE_NAME' => $role_name, + 'TITLE' => $role_description, + 'SELECTED' => $role_id == $current_role_id, + )); } if (!$current_role_id && $mode != 'view') @@ -600,7 +587,6 @@ class auth_admin extends \phpbb\auth\auth $template->assign_block_vars($tpl_pmask . '.' . $tpl_fmask, array( 'NAME' => ($forum_id == 0) ? $forum_names_ary[0] : $forum_names_ary[$forum_id]['forum_name'], 'PADDING' => ($forum_id == 0) ? '' : $forum_names_ary[$forum_id]['padding'], - 'S_ROLE_OPTIONS' => $s_role_options, 'S_CUSTOM' => $s_custom_permissions, 'UG_ID' => $ug_id, 'FORUM_ID' => $forum_id) -- cgit v1.2.1