BuddyDev

Search

BuddyPress Auto Friendship Pro – Can't get it to work

  • Participant
    Level: Enlightened
    Posts: 56
    John B on #32126

    I would like for all users that sign up to have me as a friend. I cannot figure out what settings to use to make this work. I have tried all combinations of Conditions with no luck.

    What Conditions should I be using to ensure everyone that signs up gets me as a friend?

    Member Type > Equal to > Subscriber – Doesn’t work.
    Member Type > In > Subscriber – Doesn’t work.
    No Condition at all – Doesn’t work.

    Thank you

  • Participant
    Level: Enlightened
    Posts: 56
    John B on #32127
    This reply has been marked as private.
  • Participant
    Level: Enlightened
    Posts: 56
    John B on #32128
    This reply has been marked as private.
  • Keymaster
    (BuddyDev Team)
    Posts: 24593
    Brajesh Singh on #32135

    Hi John,

    You can create a list without any condition and any member in it will be auto added as friends to new signups.

    In your case, you are not suing BuddyPress or BuddyBoss registration and that is causing the issue.

    The plugin you are using does not fire our needed action ‘bp_core_activated_user’ We can not use other action as that will mean we won’t have the profile data to take decision. Changing priority will have no effect.

    Here is a solution that I think may work. I am going to make the Friendship handler a singleton and will supply you the code to attach that to ‘user_register’. This will work for global lists.

    Regards
    Brajesh

  • Participant
    Level: Enlightened
    Posts: 56
    John B on #32139

    Awesome! Thank you! You’re the best!

  • Participant
    Level: Enlightened
    Posts: 56
    John B on #32154

    Thanks for helping with this.

  • Keymaster
    (BuddyDev Team)
    Posts: 24593
    Brajesh Singh on #32155

    Hi John,
    Thank you for the patience.

    Please upgrade to 1.0.2 and add this code in your bp-custom.php

    
    
    /**
     * Enable adding user as friend on 'user_register' hook.
     */
    add_filter( 'bp_auto_friendship_pro_enable_on_user_register', '__return_true' );
    
    

    That will enable adding friends on user registration even if they do not use BuddyPress. This only applies to global lists though.

    Regards
    Brajesh

  • Participant
    Level: Enlightened
    Posts: 56
    John B on #32173

    That worked! YOU ARE THE MAN!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

    Thank you, Thank you, Thank you!!!!!!

  • Keymaster
    (BuddyDev Team)
    Posts: 24593
    Brajesh Singh on #32192

    Thank you John.
    I am you found it useful 🙂

    Regards
    Brajesh

The topic ‘BuddyPress Auto Friendship Pro – Can't get it to work’ is closed to new replies.

This topic is: not resolved