do not fail on wrong dates

This commit is contained in:
Frédéric Péters 2013-06-26 10:07:38 +02:00
parent af4bb14004
commit 8b15521dcc
1 changed files with 4 additions and 1 deletions

View File

@ -7,7 +7,10 @@ import tabellio.config.utils
class BasePublication(object):
@property
def date_str(self):
return self.date.strftime('%d/%m/%Y')
try:
return self.date.strftime('%d/%m/%Y')
except AttributeError:
return ''
def get_authors_as_string(self):
if not self.authors: