Skip to:
Content

BuddyPress.org

Changeset 12274


Ignore:
Timestamp:
11/05/2018 08:53:13 PM (6 years ago)
Author:
boonebgorges
Message:

Correct array syntax from [12273].

Square-bracket syntax for defining arrays was introduced in PHP 5.4.

See #7476.

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-groups/classes/class-bp-groups-member.php

    r12273 r12274  
    14461446                // If the user is a sole group admin, install a site admin as their replacement.
    14471447                if ( count( groups_get_group_admins( $group_id ) ) < 2 ) {
    1448                     $admin = get_users( [
     1448                    $admin = get_users( array(
    14491449                        'blog_id' => bp_get_root_blog_id(),
    14501450                        'fields'  => 'id',
     
    14521452                        'orderby' => 'ID',
    14531453                        'role'    => 'administrator',
    1454                     ] );
     1454                    ) );
    14551455
    14561456                    if ( ! empty( $admin ) ) {
  • trunk/tests/phpunit/testcases/groups/class-bp-groups-member.php

    r12273 r12274  
    14621462        $new_user = self::factory()->user->create();
    14631463
    1464         $admin_users = get_users( [
     1464        $admin_users = get_users( array(
    14651465            'blog_id' => bp_get_root_blog_id(),
    14661466            'fields'  => 'id',
     
    14681468            'orderby' => 'ID',
    14691469            'role'    => 'administrator',
    1470         ] );
     1470        ) );
    14711471
    14721472        $admin_user = (int) $admin_users[0];
Note: See TracChangeset for help on using the changeset viewer.