Set nickname for new wp users.
authorSteve Sutton <steve@gaslightmedia.com>
Thu, 2 Aug 2018 19:19:59 +0000 (15:19 -0400)
committerSteve Sutton <steve@gaslightmedia.com>
Thu, 2 Aug 2018 19:19:59 +0000 (15:19 -0400)
If not given for wp_insert_user it defaults to login name.
Setting it to fname lname.

models/admin/contacts/index.php

index 71129b6..aec75f0 100644 (file)
@@ -332,6 +332,7 @@ class GlmMembersAdmin_contacts_index extends GlmDataContacts
                                 'user_pass' => trim($_REQUEST['password']),
                                 'first_name' => $contactInfo['fieldData']['fname'],
                                 'last_name' => $contactInfo['fieldData']['lname'],
+                                'nickname'   => $contactInfo['fieldData']['fname'] . ' ' . $contactInfo['fieldData']['lname'],
                                 'role' => $wpRole
                             )
                         );