fnp
/
librarian.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
merge ofop-red branch which should not be necessary any more
[librarian.git]
/
librarian
/
cover.py
diff --git
a/librarian/cover.py
b/librarian/cover.py
index
b53de30
..
dc64a9c
100644
(file)
--- a/
librarian/cover.py
+++ b/
librarian/cover.py
@@
-4,7
+4,7
@@
# Copyright © Fundacja Nowoczesna Polska. See NOTICE for more information.
#
import re
# Copyright © Fundacja Nowoczesna Polska. See NOTICE for more information.
#
import re
-import Image, ImageFont, ImageDraw, ImageFilter
+
from PIL
import Image, ImageFont, ImageDraw, ImageFilter
from StringIO import StringIO
from librarian import get_resource, IOFile
from StringIO import StringIO
from librarian import get_resource, IOFile
@@
-121,7
+121,10
@@
class Cover(object):
}
def __init__(self, book_info, format=None):
}
def __init__(self, book_info, format=None):
- self.author = ", ".join(auth.readable() for auth in book_info.authors)
+ try:
+ self.author = ", ".join(auth.readable() for auth in book_info.authors)
+ except AttributeError:
+ self.author = ""
self.title = book_info.title
if format is not None:
self.format = format
self.title = book_info.title
if format is not None:
self.format = format