/// <summary>Populate missing.</summary> /// /// <param name="authProvider">The authentication provider.</param> public virtual void PopulateMissing(UserOAuthProvider authProvider) { //Don't explicitly override after if values exist if (!authProvider.DisplayName.IsNullOrEmpty() && this.DisplayName.IsNullOrEmpty()) { this.DisplayName = authProvider.DisplayName; } if (!authProvider.Email.IsNullOrEmpty() && this.PrimaryEmail.IsNullOrEmpty()) { this.PrimaryEmail = authProvider.Email; } if (!authProvider.FirstName.IsNullOrEmpty()) { this.FirstName = authProvider.FirstName; } if (!authProvider.LastName.IsNullOrEmpty()) { this.LastName = authProvider.LastName; } if (!authProvider.FullName.IsNullOrEmpty()) { this.FullName = authProvider.FullName; } if (authProvider.BirthDate != null) { this.BirthDate = authProvider.BirthDate; } if (!authProvider.BirthDateRaw.IsNullOrEmpty()) { this.BirthDateRaw = authProvider.BirthDateRaw; } if (!authProvider.Country.IsNullOrEmpty()) { this.Country = authProvider.Country; } if (!authProvider.Culture.IsNullOrEmpty()) { this.Culture = authProvider.Culture; } if (!authProvider.Gender.IsNullOrEmpty()) { this.Gender = authProvider.Gender; } if (!authProvider.MailAddress.IsNullOrEmpty()) { this.MailAddress = authProvider.MailAddress; } if (!authProvider.Nickname.IsNullOrEmpty()) { this.Nickname = authProvider.Nickname; } if (!authProvider.PostalCode.IsNullOrEmpty()) { this.PostalCode = authProvider.PostalCode; } if (!authProvider.TimeZone.IsNullOrEmpty()) { this.TimeZone = authProvider.TimeZone; } }