Support » Plugin: BuddyPress Custom Profile Menu » Pro, Declaration bug?

  • Resolved jacipetersilie



    I am running pro and I get these 3 debug notifications, do you have a hint how to fix this?

    “Strict Standards: Declaration of SP_BPCPM_MenuItemComponent::setup_globals() should be compatible with BP_Component::setup_globals($args = Array) in /nas/wp/www/cluster-41320/spiritberlin/wp-content/plugins/bp-custom-profile-menu-pro/SP_BPCPM_MenuComponent.php on line 21

    Strict Standards: Declaration of SP_BPCPM_MenuItemComponent::setup_nav() should be compatible with BP_Component::setup_nav($main_nav = Array, $sub_nav = Array) in /nas/wp/www/cluster-41320/spiritberlin/wp-content/plugins/bp-custom-profile-menu-pro/SP_BPCPM_MenuComponent.php on line 21

    Strict Standards: Declaration of SP_BPCPM_MenuItemComponent::setup_admin_bar() should be compatible with BP_Component::setup_admin_bar($wp_admin_nav = Array) in /nas/wp/www/cluster-41320/spiritberlin/wp-content/plugins/bp-custom-profile-menu-pro/SP_BPCPM_MenuComponent.php on line 21″

    Thank you very much,

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author sensibleplugins


    Hi Jacob,

    I believe these warnings should be fixed if you change the function names from

    ‘SP_BPCPM_MenuItemComponent::setup_globals($args = Array)’

    We’ll working on fixing that at our side too for our next release. Thanks!


    Thank you!!

    Can you just quickly help me – I cannot find ‘SP_BPCPM_MenuItemComponent::setup_globals()’ in SP_BPCPM_MenuComponent.php using CTRL+F.

    Best wishes,

    Plugin Author sensibleplugins


    Oh the method is only called ‘setup_globals()’. ‘SP_BPCPM_MenuItemComponent::setup_globals()’ is just an indication that the method exists inside the SP_BPCPM_MenuItemComponent class.

    Hope this helps.

    All right, thanks Tarek!!

    Hi Tarek,

    Sorry to jump in on this post, but could you direct me to where I need to make the above change please?

    I went into the plugins/bp-custom-profile-menu-pro/SP_BPCPM_MenuComponent.php file, scrolled down to line 158 where it has:

    function setup_globals() {
            $globals = array();
            parent::setup_globals( $globals );

    I then change setup_globals() to setup_globals($args = Array) but I get an error of:

    Parse error: syntax error, unexpected ‘)’, expecting ‘(‘ in /var/www/vhosts/42/389622/webspace/httpdocs/ on line 158

    Where am I going wrong with this?



    Ok, have it.

    For those wondering:

    On Line 158, change
    function setup_globals() {
    function setup_globals($args = array()) {

    On Line 170, change
    function setup_nav() {
    function setup_nav($main_nav = array(), $sub_nav = array()) {

    On Line 193, change
    function setup_admin_bar() {
    function setup_admin_bar($wp_admin_nav = array()) {

    That should sort it if you need to fix the issues before the update is released.


Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Pro, Declaration bug?’ is closed to new replies.