allow no surname list to be created when needed

svn: r16044
This commit is contained in:
Benny Malengier 2010-10-24 21:57:05 +00:00
parent 209b34f359
commit 9608af29a1

View File

@ -135,7 +135,10 @@ class SurnameBase(object):
return surname
if self.surname_list:
return self.surname_list[0]
return None
else:
#self healing, add a surname to this object and return it
self.set_surname_list([Surname()])
return self.surname_list[0]
def set_primary_surname(self, surnamenr=0):
"""