Changeset 7333
- Timestamp:
- 08/01/2013 12:06:38 AM (11 years ago)
- Location:
- branches/1.8
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/1.8/bp-groups/bp-groups-classes.php
r7323 r7333 2581 2581 $rmethod = $this->class_reflection->getMethod( $method ); 2582 2582 if ( isset( $rmethod->class ) && $this->class_name === $rmethod->class ) { 2583 $callback = array( $this ->class_name, $method );2583 $callback = array( $this, $method ); 2584 2584 } 2585 2585 … … 2588 2588 $rfallback_method = $this->class_reflection->getMethod( $fallback_method ); 2589 2589 if ( isset( $rfallback_method->class ) && $this->class_name === $rfallback_method->class ) { 2590 $callback = array( $this ->class_name, $fallback_method );2590 $callback = array( $this, $fallback_method ); 2591 2591 } 2592 2592 } -
branches/1.8/tests/testcases/groups/class-bp-group-extension.php
r6997 r7333 62 62 63 63 $fallback = array( 64 'screen_callback' => array( $ class_name, 'settings_screen' ),65 'screen_save_callback' => array( $ class_name, 'settings_screen_save' ),64 'screen_callback' => array( $e, 'settings_screen' ), 65 'screen_save_callback' => array( $e, 'settings_screen_save' ), 66 66 ); 67 67 $fallbacks = array( … … 91 91 92 92 $fallback = array( 93 'screen_callback' => array( $ class_name, 'settings_screen' ),94 'screen_save_callback' => array( $ class_name, 'settings_screen_save' ),93 'screen_callback' => array( $e, 'settings_screen' ), 94 'screen_save_callback' => array( $e, 'settings_screen_save' ), 95 95 ); 96 96 $expected = array( 97 97 'create' => $fallback, 98 98 'edit' => array( 99 'screen_callback' => array( $ class_name, 'edit_screen' ),100 'screen_save_callback' => array( $ class_name, 'edit_screen_save' ),99 'screen_callback' => array( $e, 'edit_screen' ), 100 'screen_save_callback' => array( $e, 'edit_screen_save' ), 101 101 ), 102 102 'admin' => $fallback, … … 203 203 $e->_register(); 204 204 205 $this->assertEquals( array( $ class_name, 'settings_screen' ), $e->screens['create']['screen_callback'] );206 $this->assertEquals( array( $ class_name, 'settings_screen_save' ), $e->screens['create']['screen_save_callback'] );207 $this->assertEquals( array( $ class_name, 'settings_screen' ), $e->screens['admin']['screen_callback'] );208 $this->assertEquals( array( $ class_name, 'settings_screen_save' ), $e->screens['admin']['screen_save_callback'] );209 $this->assertEquals( array( $ class_name, 'edit_screen' ), $e->screens['edit']['screen_callback'] );210 $this->assertEquals( array( $ class_name, 'edit_screen_save' ), $e->screens['edit']['screen_save_callback'] );205 $this->assertEquals( array( $e, 'settings_screen' ), $e->screens['create']['screen_callback'] ); 206 $this->assertEquals( array( $e, 'settings_screen_save' ), $e->screens['create']['screen_save_callback'] ); 207 $this->assertEquals( array( $e, 'settings_screen' ), $e->screens['admin']['screen_callback'] ); 208 $this->assertEquals( array( $e, 'settings_screen_save' ), $e->screens['admin']['screen_save_callback'] ); 209 $this->assertEquals( array( $e, 'edit_screen' ), $e->screens['edit']['screen_callback'] ); 210 $this->assertEquals( array( $e, 'edit_screen_save' ), $e->screens['edit']['screen_save_callback'] ); 211 211 } 212 212
Note: See TracChangeset
for help on using the changeset viewer.