mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-12 11:44:08 +02:00
[ticket/14972] replace all occurrences of sizeof() with the count()
PHPBB3-14972
This commit is contained in:
@@ -187,7 +187,7 @@ class acp_groups
|
||||
|
||||
group_user_attributes('default', $group_id, $mark_ary, false, $group_name, $group_row);
|
||||
|
||||
$start = (sizeof($mark_ary) < 200) ? 0 : $start + 200;
|
||||
$start = (count($mark_ary) < 200) ? 0 : $start + 200;
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -486,7 +486,7 @@ class acp_groups
|
||||
$error = array_merge($error, $validation_error);
|
||||
}
|
||||
|
||||
if (!sizeof($error))
|
||||
if (!count($error))
|
||||
{
|
||||
// Only set the rank, colour, etc. if it's changed or if we're adding a new
|
||||
// group. This prevents existing group members being updated if no changes
|
||||
@@ -614,7 +614,7 @@ class acp_groups
|
||||
}
|
||||
}
|
||||
|
||||
if (sizeof($error))
|
||||
if (count($error))
|
||||
{
|
||||
$error = array_map(array(&$user, 'lang'), $error);
|
||||
$group_rank = $submit_ary['rank'];
|
||||
@@ -732,12 +732,12 @@ class acp_groups
|
||||
'S_ADD_GROUP' => ($action == 'add') ? true : false,
|
||||
'S_GROUP_PERM' => ($action == 'add' && $auth->acl_get('a_authgroups') && $auth->acl_gets('a_aauth', 'a_fauth', 'a_mauth', 'a_uauth')) ? true : false,
|
||||
'S_INCLUDE_SWATCH' => true,
|
||||
'S_ERROR' => (sizeof($error)) ? true : false,
|
||||
'S_ERROR' => (count($error)) ? true : false,
|
||||
'S_SPECIAL_GROUP' => ($group_type == GROUP_SPECIAL) ? true : false,
|
||||
'S_USER_FOUNDER' => ($user->data['user_type'] == USER_FOUNDER) ? true : false,
|
||||
'S_AVATARS_ENABLED' => ($config['allow_avatar'] && $avatars_enabled),
|
||||
|
||||
'ERROR_MSG' => (sizeof($error)) ? implode('<br />', $error) : '',
|
||||
'ERROR_MSG' => (count($error)) ? implode('<br />', $error) : '',
|
||||
'GROUP_NAME' => $group_helper->get_name($group_name),
|
||||
'GROUP_INTERNAL_NAME' => $group_name,
|
||||
'GROUP_DESC' => $group_desc_data['text'],
|
||||
|
Reference in New Issue
Block a user