Applications pending on a site are approved or rejected under Users > Pending Approval, with the Approve Member(s) and Reject Member(s) bulk actions, or over MCP with the approve-applications and reject-applications abilities (see Abilities). Both paths run the same code.
The abilities act only on applicants pending on the site at that moment. Anyone else (already a member, already decided, or not an applicant) is skipped and reported, so repeating a call is harmless. They need add_users on the site and take site_id, so one connector can work through any site’s queue. When called for another site, the welcome email uses that site’s own template and details.
core-user-activation), as each site has edited it.lh-membership-application-rejected), a BuddyPress email added by LH Membership. It is created on a site the first time an application there is rejected, then edited under Emails like any other. BuddyPress’s reinstall-emails tool also restores it.message, such as a welcome note or the reason for a rejection. It goes where the email has the {{{membership.message}}} placeholder, or above the body if there is none. With no message nothing is added and the placeholder is removed. The bulk actions send the same emails without a message.lh_membership_make_user_member_in_backend_before_email ( int $user_id ): during approval, after the member type and roles are set and before the welcome email.lh_membership_make_user_member_in_backend ( int $user_id ): after an application is approved and the welcome email sent.lh_membership_decline_application_in_backend ( int $user_id ): after an application is rejected.The code is LH_Membership_onboarding_admin_class::make_user_member_in_backend() and decline_application_in_backend(), with the emails in includes/lh-membership-application-emails-class.php. (Since 2.99.0; before-email hook since 2.102.0.)