Changeset 4294 for trunk/bp-messages/bp-messages-functions.php
- Timestamp:
- 04/25/2011 02:25:30 PM (15 years ago)
- File:
-
- 1 edited
-
trunk/bp-messages/bp-messages-functions.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/bp-messages/bp-messages-functions.php
r4164 r4294 58 58 // Loop the recipients and convert all usernames to user_ids where needed 59 59 foreach( (array) $recipients as $recipient ) { 60 if ( is_numeric( trim( $recipient ) ) ) 61 $recipient_ids[] = (int)trim( $recipient ); 62 63 if ( $recipient_id = bp_core_get_userid( trim( $recipient ) ) ) 64 $recipient_ids[] = (int)$recipient_id; 60 $recipient = trim( $recipient ); 61 if ( empty( $recipient ) ) 62 continue; 63 64 if ( is_numeric( $recipient ) ) { 65 if ( bp_core_get_core_userdata( (int) $recipient ) ) 66 $recipient_ids[] = (int) $recipient; 67 68 } else { 69 if ( defined( 'BP_ENABLE_USERNAME_COMPATIBILITY_MODE' ) ) 70 $recipient_id = bp_core_get_userid( $recipient ); 71 else 72 $recipient_id = bp_core_get_userid_from_nicename( $recipient ); 73 74 $recipient_ids[] = (int) $recipient_id; 75 } 65 76 } 66 77
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)