diff --git src/bp-groups/classes/class-bp-group-extension.php src/bp-groups/classes/class-bp-group-extension.php
index 208e2ff..ac4b860 100644
|
|
class BP_Group_Extension { |
974 | 974 | if ( '' !== bp_locate_template( array( 'groups/single/home.php' ), false ) ) { |
975 | 975 | $this->edit_screen_template = '/groups/single/home'; |
976 | 976 | } else { |
977 | | add_action( 'bp_template_content_header', create_function( '', 'echo "<ul class=\"content-header-nav\">"; bp_group_admin_tabs(); echo "</ul>";' ) ); |
| 977 | add_action( 'bp_template_content_header', function() { |
| 978 | echo '<ul class="content-header-nav">'; |
| 979 | bp_group_admin_tabs(); |
| 980 | echo '</ul>'; |
| 981 | } ); |
978 | 982 | add_action( 'bp_template_content', array( &$this, 'call_edit_screen' ) ); |
979 | 983 | $this->edit_screen_template = '/groups/single/plugins'; |
980 | 984 | } |
… |
… |
function bp_register_group_extension( $group_extension_class = '' ) { |
1690 | 1694 | |
1691 | 1695 | // Register the group extension on the bp_init action so we have access |
1692 | 1696 | // to all plugins. |
1693 | | add_action( 'bp_init', create_function( '', ' |
1694 | | $extension = new ' . $group_extension_class . '; |
1695 | | add_action( "bp_actions", array( &$extension, "_register" ), 8 ); |
1696 | | add_action( "admin_init", array( &$extension, "_register" ) ); |
1697 | | ' ), 11 ); |
| 1697 | add_action( 'bp_init', function() use ( $group_extension_class ) { |
| 1698 | $extension = new $group_extension_class; |
| 1699 | add_action( 'bp_actions', array( &$extension, '_register' ), 8 ); |
| 1700 | add_action( 'admin_init', array( &$extension, '_register' ) ); |
| 1701 | }, 11 ); |
1698 | 1702 | } |