diff --git a/gramps/src/Date.py b/gramps/src/Date.py index e93266415..a611a945a 100644 --- a/gramps/src/Date.py +++ b/gramps/src/Date.py @@ -61,11 +61,20 @@ class Date: match = Date.fmt.match(text) if match: matches = match.groups() - self.start.set(matches[1]) - self.stop.set(matches[3]) + try: + self.start.set(matches[1]) + except: + pass + try: + self.stop.set(matches[3]) + except: + pass self.range = 1 else: - self.start.set(text) + try: + self.start.set(text) + except: + pass self.range = 0 #-------------------------------------------------------------------- @@ -102,11 +111,20 @@ class Date: match = Date.fmt.match(text) if match: matches = match.groups() - self.start.set(matches[1]) - self.stop.set(matches[3]) + try: + self.start.set(matches[1]) + except: + pass + try: + self.stop.set(matches[3]) + except: + pass self.range = 1 else: - self.start.quick_set(text) + try: + self.start.quick_set(text) + except: + pass self.range = 0 #-------------------------------------------------------------------------