diff --git a/Clue.py b/Clue.py index af366a8..b56d8ce 100644 --- a/Clue.py +++ b/Clue.py @@ -234,8 +234,11 @@ def email(self): return self.emails()[0] def birthday(self): - if self.person.valueForProperty_( kABBirthdayProperty ): - return gmtime( self.person.valueForProperty_( kABBirthdayProperty ).timeIntervalSince1970() ) + try: + if self.person.valueForProperty_( kABBirthdayProperty ): + return gmtime( self.person.valueForProperty_( kABBirthdayProperty ).timeIntervalSince1970() ) + except ValueError: # too old.. TODO - Um, I know people born <1970. Must fix. + pass return None # utility method for dealing with the Cocoa Address Book interface.