Make WordPress Core


Ignore:
Timestamp:
09/05/2013 04:33:50 PM (13 years ago)
Author:
wonderboymusic
Message:

Remove lingering instances of call time pass-by-reference, limited to instances of callable - use $this instead of &$this.

Props jdgrimes.
See #25160.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/tests/user/capabilities.php

    r25002 r25254  
    509509                        $this->assertFalse( $admin->has_cap('delete_post_meta', $post, '_protected') );
    510510
    511                         register_meta( 'post', '_protected', array( &$this, '_meta_filter' ), array( &$this, '_meta_yes_you_can' ) );
     511                        register_meta( 'post', '_protected', array( $this, '_meta_filter' ), array( $this, '_meta_yes_you_can' ) );
    512512                        $this->assertTrue( $admin->has_cap('edit_post_meta',  $post, '_protected') );
    513513                        $this->assertTrue( $admin->has_cap('add_post_meta',  $post, '_protected') );
    … …  
    518518                        $this->assertTrue( $admin->has_cap('delete_post_meta', $post, 'not_protected') );
    519519
    520                         register_meta( 'post', 'not_protected', array( &$this, '_meta_filter' ), array( &$this, '_meta_no_you_cant' ) );
     520                        register_meta( 'post', 'not_protected', array( $this, '_meta_filter' ), array( $this, '_meta_no_you_cant' ) );
    521521                        $this->assertFalse( $admin->has_cap('edit_post_meta',  $post, 'not_protected') );
    522522                        $this->assertFalse( $admin->has_cap('add_post_meta',  $post, 'not_protected') );
Note: See TracChangeset for help on using the changeset viewer.