Fix EditFamily for adding a child to single parent family with (#777)

Surname guessing set to combination.

Fixes #10997
This commit is contained in:
Paul Culley 2019-02-02 16:30:45 -06:00 committed by Sam Manzi
parent 4c6c052729
commit b4e4dbbcf2

View File

@ -292,9 +292,11 @@ class ChildEmbedList(EmbeddedList):
name.set_primary_surname(0) name.set_primary_surname(0)
if self.family: if self.family:
father_handle = self.family.get_father_handle() father_handle = self.family.get_father_handle()
father = (self.dbstate.db.get_person_from_handle(father_handle) if
father_handle else None)
mother_handle = self.family.get_mother_handle() mother_handle = self.family.get_mother_handle()
father = self.dbstate.db.get_person_from_handle(father_handle) mother = (self.dbstate.db.get_person_from_handle(mother_handle) if
mother = self.dbstate.db.get_person_from_handle(mother_handle) mother_handle else None)
if not father and not mother: if not father and not mother:
return name return name
if not father: if not father: