Skip to:
Content

BuddyPress.org

Changeset 11760


Ignore:
Timestamp:
12/06/2017 03:32:04 PM (3 years ago)
Author:
djpaul
Message:

Members, Groups: add user ID to user autocomplete data.

Fixes #7601

Location:
trunk/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-core/classes/class-bp-members-suggestions.php

    r10417 r11760  
    118118
    119119        foreach ( $user_query->results as $user ) {
    120             $result        = new stdClass();
    121             $result->ID    = $user->user_nicename;
    122             $result->image = bp_core_fetch_avatar( array( 'html' => false, 'item_id' => $user->ID ) );
    123             $result->name  = bp_core_get_user_displayname( $user->ID );
     120            $result          = new stdClass();
     121            $result->ID      = $user->user_nicename;
     122            $result->image   = bp_core_fetch_avatar( array( 'html' => false, 'item_id' => $user->ID ) );
     123            $result->name    = bp_core_get_user_displayname( $user->ID );
     124            $result->user_id = $user->ID;
    124125
    125126            $results[] = $result;
  • trunk/src/bp-groups/classes/class-bp-groups-member-suggestions.php

    r11100 r11760  
    152152        $results = array();
    153153        foreach ( $user_query->results as $user ) {
    154             $result        = new stdClass();
    155             $result->ID    = $user->user_nicename;
    156             $result->image = bp_core_fetch_avatar( array( 'html' => false, 'item_id' => $user->ID ) );
    157             $result->name  = bp_core_get_user_displayname( $user->ID );
     154            $result          = new stdClass();
     155            $result->ID      = $user->user_nicename;
     156            $result->image   = bp_core_fetch_avatar( array( 'html' => false, 'item_id' => $user->ID ) );
     157            $result->name    = bp_core_get_user_displayname( $user->ID );
     158            $result->user_id = $user->ID;
    158159
    159160            $results[] = $result;
Note: See TracChangeset for help on using the changeset viewer.