* src/plugins/Check.py (check_for_broken_family_links): Check if
child is one of the parents. svn: r7714
This commit is contained in:
parent
be83b6f8ba
commit
c689bcc39f
@ -3,6 +3,8 @@
|
|||||||
* po/gramps.pot: updated
|
* po/gramps.pot: updated
|
||||||
|
|
||||||
2006-11-26 Alex Roitman <shura@gramps-project.org>
|
2006-11-26 Alex Roitman <shura@gramps-project.org>
|
||||||
|
* src/plugins/Check.py (check_for_broken_family_links): Check if
|
||||||
|
child is one of the parents.
|
||||||
* src/GrampsDb/_GrampsBSDDB.py (load): Clean env for a new grdb
|
* src/GrampsDb/_GrampsBSDDB.py (load): Clean env for a new grdb
|
||||||
file; do not attempt recovery for a new grdb file.
|
file; do not attempt recovery for a new grdb file.
|
||||||
* NEWS: Typo.
|
* NEWS: Typo.
|
||||||
|
@ -354,6 +354,13 @@ class CheckIntegrity:
|
|||||||
child_handle = child_ref.ref
|
child_handle = child_ref.ref
|
||||||
child = self.db.get_person_from_handle(child_handle)
|
child = self.db.get_person_from_handle(child_handle)
|
||||||
if child:
|
if child:
|
||||||
|
if child_handle in [father_handle,mother_handle]:
|
||||||
|
# The child is one of the parents: impossible
|
||||||
|
# Remove such child from the family
|
||||||
|
family.remove_child_ref(child_ref)
|
||||||
|
self.db.commit_family(family,self.trans)
|
||||||
|
self.broken_links.append((child_handle,family_handle))
|
||||||
|
continue
|
||||||
if family_handle == child.get_main_parents_family_handle():
|
if family_handle == child.get_main_parents_family_handle():
|
||||||
continue
|
continue
|
||||||
if family_handle not in \
|
if family_handle not in \
|
||||||
|
Loading…
Reference in New Issue
Block a user