if (!result.hasErrors()) {
uploadProfilePictureIfEntered(dto, researcher);
researcher.setSalt(getRandomSalt());
researcher.setPassword(getHashedPassword(dto.getPassword(), researcher.getSalt()));
researcher.persist();
String message = generateMessage(accountCreatedMessage, new Object[] {researcher.getEmail(), applicationUrl});
messageSender.sendMessage("Community Profile Database Account Created", researcher.getEmail(), message);
}
}