Changeset 12920
- Timestamp:
- 04/28/2021 11:50:46 PM (3 years ago)
- Location:
- trunk/src/bp-members
- Files:
-
- 2 added
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bp-members/classes/class-bp-members-component.php
r12917 r12920 139 139 // Theme compatibility. 140 140 new BP_Registration_Theme_Compat(); 141 } 142 143 // Invitations. 144 if ( is_user_logged_in() && bp_is_user_members_invitations() ) { 145 if ( bp_is_user_members_invitations_list() ) { 146 require $this->path . 'bp-members/screens/list-invites.php'; 147 } else { 148 require $this->path . 'bp-members/screens/send-invites.php'; 149 } 141 150 } 142 151 } -
trunk/src/bp-members/screens/register.php
r12875 r12920 43 43 $bp->signup->step = 'request-details'; 44 44 45 if ( !bp_get_signup_allowed() ) { 45 // Could the user be accepting an invitation? 46 $active_invite = false; 47 if ( bp_get_members_invitations_allowed() ) { 48 // Check to see if there's a valid invitation. 49 $maybe_invite = bp_get_members_invitation_from_request(); 50 if ( $maybe_invite->id && $maybe_invite->invitee_email ) { 51 // Check if this user is already a member. 52 $args = array( 53 'invitee_email' => $maybe_invite->invitee_email, 54 'accepted' => 'accepted', 55 'fields' => 'ids', 56 ); 57 $accepted_invites = bp_members_invitations_get_invites( $args ); 58 if ( ! $accepted_invites ) { 59 $active_invite = true; 60 } 61 } 62 } 63 64 if ( ! bp_get_signup_allowed() && ! $active_invite ) { 46 65 $bp->signup->step = 'registration-disabled'; 47 48 66 // If the signup page is submitted, validate and save. 49 67 } elseif ( isset( $_POST['signup_submit'] ) && bp_verify_nonce_request( 'bp_new_signup' ) ) {
Note: See TracChangeset
for help on using the changeset viewer.