From the creators of Nextend Social Login: Meet Mosaic, a visual workflow built on real web fundamentals for WordPress.
Try now

How to override the userdata (username/email) before registration?

You can override the username or the email in the $userData using the nsl_registration_user_data filter.

Example

Code
add_filter('nsl_registration_user_data', function($userData, $provider){
    $userData['username']=$provider->getAuthUserData('first_name').'-'.$provider->getAuthUserData('last_name');
            
    return $userData;
},10,2);

Available since: 3.0.15

Your cookie preferences

We use cookies to improve your experience, analyze traffic, and personalize content. By clicking "Accept all" you agree to storing them on your device. Read our privacy policy.