Logger.debug("editContact request body: " + reqBody);
ContactDTO contactDTO = new ObjectMapper().readValue(reqBody, ContactDTO.class);
contactDTO.mapBack(contact);
DaoManager.getContactDao().persist(contact);
List<Phone> editedPhones = new ArrayList<Phone>();
Phone p;
Logger.info("1");
for(PhoneListItemDTO phone: contactDTO.getPhones()) {
p = new Phone();
phone.mapBack(p);
p.setContact(contact);
editedPhones.add(p);
DaoManager.getPhoneDao().persist(p);
}
Logger.info("3");
loop: for(PhoneListItemDTO ph1: phones) {