Skip to content

Instantly share code, notes, and snippets.

@raftaar1191
Created August 31, 2023 19:55
Show Gist options
  • Save raftaar1191/92082cc8cf134e750d8c05369b815c86 to your computer and use it in GitHub Desktop.
Save raftaar1191/92082cc8cf134e750d8c05369b815c86 to your computer and use it in GitHub Desktop.
Patch to fixed the Group menu issue that came in version BB theme version: 2.4.01
/**
* Temp patch for Group Menu issue in the BB theme version: 2.4.01
*/
function awp_add_boss_menu_js_functions() {
if(
function_exists( 'bp_get_group_current_admin_tab' )
&& in_array( bp_get_group_current_admin_tab(), array( 'edit-details', 'group-settings', 'group-avatar', 'group-cover-image', 'manage-members', 'membership-requests', 'delete-group', 'forum' ), true )
) {
?>
<script type="text/javascript">
( function ( $ ) {
$.fn.BossSocialMenu = function ( reduceWidth ) {
}
}( jQuery ) );
</script>
<?php
}
}
add_action( 'wp_footer', 'awp_add_boss_menu_js_functions', 1000 );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment