Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
11/07/2010 12:20:02 AM (16 years ago)
Author:
djpaul
Message:

Fixes even more WP_DEBUG warnings.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/bp-xprofile/bp-xprofile-classes.php

    r3357 r3369  
    9494                extract( $r, EXTR_SKIP );
    9595
     96                $group_id_sql = '';
    9697                if ( $profile_group_id )
    9798                        $group_id_sql = $wpdb->prepare( 'WHERE g.id = %d', $profile_group_id );
    … …  
    258259                global $wpdb, $userdata, $bp;
    259260
     261                $user_id = 0;
    260262                if ( is_null( $user_id ) )
    261263                        $user_id = $userdata->ID;
    … …  
    264266
    265267                if ( $field = $wpdb->get_row( $sql ) ) {
    266                         $this->id                                       = $field->id;
    267                         $this->group_id                         = $field->group_id;
    268                         $this->parent_id                        = $field->parent_id;
    269                         $this->type                                     = $field->type;
    270                         $this->name                                     = stripslashes($field->name);
    271                         $this->description                      = stripslashes($field->description);
    272                         $this->is_required                      = $field->is_required;
    273                         $this->can_delete                       = $field->can_delete;
    274                         $this->field_order                      = $field->field_order;
    275                         $this->option_order                     = $field->option_order;
    276                         $this->order_by                         = $field->order_by;
    277                         $this->is_default_option        = $field->is_default_option;
    278 
    279                         if ( $get_data )
    280                                 $this->data                             = $this->get_field_data( $user_id );
    281 
     268                        $this->id               = $field->id;
     269                        $this->group_id          = $field->group_id;
     270                        $this->parent_id         = $field->parent_id;
     271                        $this->type              = $field->type;
     272                        $this->name              = stripslashes( $field->name );
     273                        $this->description       = stripslashes( $field->description );
     274                        $this->is_required       = $field->is_required;
     275                        $this->can_delete        = $field->can_delete;
     276                        $this->field_order       = $field->field_order;
     277                        $this->option_order      = $field->option_order;
     278                        $this->order_by          = $field->order_by;
     279                        $this->is_default_option = $field->is_default_option;
     280
     281                        if ( $get_data && $user_id )
     282                                $this->data            = $this->get_field_data( $user_id );
    282283                }
    283284        }
Note: See TracChangeset for help on using the changeset viewer.