final ValueFactory valueFactory = session.getValueFactory();
final boolean firstnameUpdated = updateUserProperty(user, valueFactory, FIRSTNAME_PROPERTY, xingUser.getFirstName());
final boolean lastnameUpdated = updateUserProperty(user, valueFactory, LASTNAME_PROPERTY, xingUser.getLastName());
if (firstnameUpdated || lastnameUpdated) {
session.save();
}
return user;
} catch (Exception e) {
logger.error(e.getMessage(), e);