LLMS_PlayNice::buddyboss_compatibility()
Compatibility for BuddyBoss.
Return Return
(void)
Source Source
File: includes/class.llms.playnice.php
73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 | public function buddyboss_compatibility() { if ( ! function_exists( 'is_plugin_active' ) || ! function_exists( 'bp_is_my_profile' ) || bp_is_my_profile() ) { return ; } if ( is_plugin_active( 'buddyboss-platform/bp-loader.php' ) || ( is_multisite() && is_plugin_active_for_network( 'buddyboss-platform/bp-loader.php' ) ) ) { $plugin_data = get_plugin_data( trailingslashit( WP_PLUGIN_DIR ) . 'buddyboss-platform/bp-loader.php' ); $plugin_version = ! empty ( $plugin_data [ 'Version' ] ) ? $plugin_data [ 'Version' ] : 0; if ( $plugin_version && version_compare( $plugin_version , '2.0.3' , '>=' ) ) { // Nothing to do. return ; } } // Do not add our profile nav items when not in front-end (and not in "my profile"), to avoid a fatal error. $bp_integration = llms()->integrations()->get_integration( 'buddypress' ); remove_action( 'bp_setup_nav' , array ( $bp_integration , 'add_profile_nav_items' ) ); } |
Expand full source code Collapse full source code View on GitHub
Changelog Changelog
Version | Description |
---|---|
6.8.0 | Introduced. |