Fix of issue #2226.

svn: r10813
This commit is contained in:
Peter Landgren 2008-06-17 14:02:08 +00:00
parent 4982292774
commit de6b1f80c2

View File

@ -2117,7 +2117,7 @@ def find_marriage(database, family):
for event_ref in family.get_event_ref_list():
event = database.get_event_from_handle(event_ref.ref)
if event and event.type.value == EventType.MARRIAGE \
and event_ref.role.value == EventRoleType.PRIMARY:
and event_ref.role.value == EventRoleType.FAMILY:
return event
return None