* src/Merge.py: fix date comparison

svn: r5515
This commit is contained in:
Don Allingham 2005-12-09 04:14:24 +00:00
parent f3ae05e28a
commit c4d894920b
2 changed files with 3 additions and 2 deletions

View File

@ -1,4 +1,5 @@
2005-12-08 Don Allingham <don@gramps-project.org>
* src/Merge.py: fix date comparison
* src/Utils.py: add xml:lang generation function
* src/docgen/AbiWord2Doc.py: set locale
* src/docgen/OpenOfficeDoc: set locale using xml_lang()

View File

@ -374,7 +374,7 @@ class Merge(Tool.Tool):
return s1 == s2
def date_match(self,date1,date2):
if date1.is_empty() == "" or date2.is_empty() == "":
if date1.is_empty() or date2.is_empty():
return 0
if date1.is_equal(date2):
return 1
@ -514,7 +514,7 @@ class Merge(Tool.Tool):
else:
death2 = RelLib.Event()
value = self.date_match(birth1.get_date_object(),birth2.get_date_object())
value = self.date_match(birth1.get_date_object(),birth2.get_date_object())
if value == -1 :
return -1
chance = chance + value