if(rollerDetails.getLocale() != null) {
ud.setLocale(rollerDetails.getLocale());
}
} else if(userDetails instanceof LdapUserDetails) {
LdapUserDetails ldapDetails = (LdapUserDetails) userDetails;
Attributes attributes = ldapDetails.getAttributes();
String name = getLdapAttribute(attributes, RollerConfig.getProperty(NAME_LDAP_PROPERTY, DEFAULT_NAME_LDAP_ATTRIBUTE));
String email = getLdapAttribute(attributes, RollerConfig.getProperty(EMAIL_LDAP_PROPERTY, DEFAULT_EMAIL_LDAP_ATTRIBUTE));
ud.setFullName(name);
ud.setEmailAddress(email);