Skip to:
Content

BuddyPress.org

Changeset 5602


Ignore:
Timestamp:
12/26/2011 09:54:18 PM (14 years ago)
Author:
johnjamesjacoby
Message:

Skip isset() check in bp_get_name_from_root_slug(); !empty() handles this already.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/bp-core/bp-core-template.php

    r5479 r5602  
    701701
    702702    // Loop through active components and look for a match
    703     foreach ( $bp->active_components as $component => $id )
    704         if (    isset( $bp->{$component}->root_slug ) &&
    705                 !empty( $bp->{$component}->root_slug ) &&
    706                 $bp->{$component}->root_slug == $root_slug )
     703    foreach ( $bp->active_components as $component => $id ) {
     704        if ( !empty( $bp->{$component}->root_slug ) && ( $bp->{$component}->root_slug == $root_slug ) ) {
    707705            return $bp->{$component}->name;
     706        }
     707    }
    708708
    709709    return false;
Note: See TracChangeset for help on using the changeset viewer.