Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
08/22/2016 10:11:20 PM (8 years ago)
Author:
r-a-y
Message:

Groups: Cast properties as integers where appropriate.

See #6977.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-groups/bp-groups-functions.php

    r10978 r11027  
    115115    // Pass an existing group ID.
    116116    if ( ! empty( $group_id ) ) {
    117         $group = groups_get_group( array( 'group_id' => (int) $group_id ) );
     117        $group = groups_get_group( array( 'group_id' => $group_id ) );
    118118        $name  = ! empty( $name ) ? $name : $group->name;
    119119        $slug  = ! empty( $slug ) ? $slug : $group->slug;
     
    416416 *
    417417 * @param string $group_slug The group's slug.
    418  * @return int The ID.
     418 * @return int|null The group ID on success; null on failure.
    419419 */
    420420function groups_get_id( $group_slug ) {
    421     return (int)BP_Groups_Group::group_exists( $group_slug );
     421    return BP_Groups_Group::group_exists( $group_slug );
    422422}
    423423
Note: See TracChangeset for help on using the changeset viewer.