Skip to:
Content

BuddyPress.org

Changeset 9119


Ignore:
Timestamp:
11/03/2014 04:57:28 PM (5 years ago)
Author:
djpaul
Message:

Core: partial revert of r9116 (user->id to user->ID changes).

In our legacy user fetching functions, we use something similar to "select ... ID as id" in the SQL. In the reverted changes, we are only using the property to return an array of integers, and the change of the property name was causing PHP to throw "undefined property" messages.

As these lines would have never thrown a WordPress core deprecated warning about using id instead of ID, I'm changing them back to clear the warning message and fix the unit tests.

See #5979

File:
1 edited

Legend:

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

    r9116 r9119  
    10641064
    10651065            foreach ( (array) $paged_users as $user ) {
    1066                 $user_ids[] = $user->ID;
     1066                $user_ids[] = $user->id;
    10671067            }
    10681068
     
    11351135        $user_ids = array();
    11361136        foreach ( (array) $paged_users as $user )
    1137             $user_ids[] = (int) $user->ID;
     1137            $user_ids[] = (int) $user->id;
    11381138
    11391139        // Add additional data to the returned results
     
    12231223         */
    12241224        foreach ( (array) $paged_users as $user )
    1225             $user_ids[] = $user->ID;
     1225            $user_ids[] = $user->id;
    12261226
    12271227        // Add additional data to the returned results
Note: See TracChangeset for help on using the changeset viewer.