String lastInsertFingerprint = configuration.getStringValue(sonePrefix + "/LastInsertFingerprint").getValue("");
/* load profile. */
- Profile profile = new Profile();
+ Profile profile = new Profile(sone);
profile.setFirstName(configuration.getStringValue(sonePrefix + "/Profile/FirstName").getValue(null));
profile.setMiddleName(configuration.getStringValue(sonePrefix + "/Profile/MiddleName").getValue(null));
profile.setLastName(configuration.getStringValue(sonePrefix + "/Profile/LastName").getValue(null));
/* load avatar. */
String avatarId = configuration.getStringValue(sonePrefix + "/Profile/Avatar").getValue(null);
if (avatarId != null) {
- sone.setAvatar(getImage(avatarId, false));
+ profile.setAvatar(getImage(avatarId, false));
}
/* load options. */
configuration.getIntValue(sonePrefix + "/Profile/BirthDay").setValue(profile.getBirthDay());
configuration.getIntValue(sonePrefix + "/Profile/BirthMonth").setValue(profile.getBirthMonth());
configuration.getIntValue(sonePrefix + "/Profile/BirthYear").setValue(profile.getBirthYear());
- configuration.getStringValue(sonePrefix + "/Profile/Avatar").setValue(sone.getAvatar());
+ configuration.getStringValue(sonePrefix + "/Profile/Avatar").setValue(profile.getAvatar());
/* save profile fields. */
int fieldCounter = 0;