Skip to:
Content

BuddyPress.org

Changeset 7288


Ignore:
Timestamp:
07/22/2013 05:35:06 PM (7 years ago)
Author:
boonebgorges
Message:

Remove pass-by-reference for objects in selected places in BP

Since PHP 5.0, objects have been passed by reference by default. In more recent
versions of PHP, standards notices have been introduced to increasingly
deprecate the practice of passing objects by reference using an ampersand.

This changeset removes several of these strict standard notices, by removing
the explicit pass-by-reference for the objects in question.

See #5108

Location:
trunk
Files:
2 edited

Legend:

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

    r7228 r7288  
    365365    // Make the queried/post object an actual valid page
    366366    if ( !empty( $object_id ) ) {
    367         $wp_query->queried_object    = &get_post( $object_id );
     367        $wp_query->queried_object    = get_post( $object_id );
    368368        $wp_query->queried_object_id = $object_id;
    369369        $post                        = $wp_query->queried_object;
     
    655655
    656656    if ( !$include_query_args ) {
    657         $canonical_url = array_pop( array_reverse( explode( '?', $canonical_url ) ) );
     657        $canonical_url = array_reverse( explode( '?', $canonical_url ) );
     658        $canonical_url = array_pop( $canonical_url );
    658659    }
    659660
  • trunk/bp-loader.php

    r7287 r7288  
    600600// "And now here's something we hope you'll really like!"
    601601} else {
    602     $GLOBALS['bp'] = &buddypress();
     602    $GLOBALS['bp'] = buddypress();
    603603}
    604604
Note: See TracChangeset for help on using the changeset viewer.