Fix authors_to_string error with NoneType objects

This commit is contained in:
John Schember 2009-01-24 08:46:23 -05:00
parent df88a9dfaa
commit 1556b1497a

View File

@ -21,7 +21,10 @@ def string_to_authors(raw):
return authors
def authors_to_string(authors):
return ' & '.join([a.replace('&', '&&') for a in authors])
if authors is not None:
return ' & '.join([a.replace('&', '&&') for a in authors])
else:
return ''
def author_to_author_sort(author):
tokens = author.split()