• Resolved besmart76

    (@besmart76)


    Good evening. Since the last global plugin update within my site, User Switch plugin conflicts with BuddyPress and WooCommerce. When I try to switch from one user to another I am logged out of WordPress and sent back to the homepage.
    The current versions of the plugins are: BuddyPress 12.2.0 and WooCommerce 8.5.2. WordPress version 6.4.3.
    Can you help me? Thank you.

Viewing 8 replies - 1 through 8 (of 8 total)
  • Plugin Author John Blackbourn

    (@johnbillion)

    WordPress Core Developer

    Thanks for the report. I’m not seeing any problems on the WooCommerce sites that I manage.

    Are you able to test this with either one of the other plugins deactivated in order to find where the conflict is? And if you can test with both deactivated too that would help.

    Thread Starter besmart76

    (@besmart76)

    HI. Thank you for your answer. I had written that the conflict was not only with WooCommerce but also with BuddyPress.
    Unfortunately this is a site that has various plugins inside that need a user area: BuddyPress, Youzify, Tutor LMS and WooCommerce. I think it’s obvious that something conflicts. The customer independently installs new plugins and it was he who installed User switching to help users who sign up with data management.
    I deactivated all plugins locally and the conflict issue occurs when BuddyPress (also WooCommerce) is active.
    Are there any suggestions in this case?
    Thanks.

    Plugin Author John Blackbourn

    (@johnbillion)

    WordPress Core Developer

    Is there a setting in BuddyPress that controls where a user gets redirected to after logging in or logging out? Perhaps that is interfering with User Switching.

    Eder Ribeiro

    (@ribeiroeder)

    Hi, I can confirm that there is a conflict with BuddyPress version 12 and later. They rewrote several functions, below is a copy of the error generated when accessing the general membership page:

    PHP Fatal error: ?Uncaught Error: Call to undefined function bp_core_get_user_domain() in /home/XXX/wp-content/plugins/user-switching/user-switching.php:761 Stack trace: 
    
    #0 /home/XXXX/wp-includes/class-wp-hook.php(324): user_switching->action_bp_button('') 
    
    #1 /home/XXXX/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters('', Array) 
    
    #2 /home/XXXX/wp-includes/plugin.php(517): WP_Hook->do_action(Array) 
    
    #3 /home/XXXX/wp-content/plugins/buddypress/bp-templates/bp-nouveau/includes/members/template-tags.php(198): do_action('bp_directory_me...') 
    
    #4 /home/XXXX/wp-content/plugins/buddypress/bp-templates/bp-nouveau/buddypress/members/members-loop.php(53): bp_nouveau_members_loop_buttons(Array) 
    
    #5 /home/XXXX/wp-includes/template.php(790): require_once('/home/icllms/pu...') 
    
    #6 /home/XXXX/wp-content/plugins/buddypress/bp-templates/bp-nouveau/includes/ajax.php(150): load_template('/home/icllms/pu...') 
    
    #7 /home/XXXX/wp-includes/class-wp-hook.php(324): bp_nouveau_ajax_object_template_loader('') 
    
    #8 /home/XXXX/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters('', Array) 
    
    #9 /home/XXXX/wp-includes/plugin.php(517): WP_Hook->do_action(Array) 
    
    #10 /home/XXXX/wp-admin/admin-ajax.php(188): do_action('wp_ajax_members...') 
    
    #11 {main} ? thrown in /home/XXXX/wp-content/plugins/user-switching/user-switching.php on line 761
    Eder Ribeiro

    (@ribeiroeder)

    Function bp_core_get_user_domain() is deprecated since version 12.0.0. Use bp_members_get_user_url() instead

    Plugin Author John Blackbourn

    (@johnbillion)

    WordPress Core Developer

    Thanks, I’ll take a look ??

    Plugin Author John Blackbourn

    (@johnbillion)

    WordPress Core Developer

    I’ve fixed this in the latest version of User Switching. Cheers!

    Eder Ribeiro

    (@ribeiroeder)

    Great! Thanks

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Conflict with other plugins’ is closed to new replies.