diff --git a/src/calibre/ebooks/fb2/input.py b/src/calibre/ebooks/fb2/input.py index 3c62b9671d..147e940eb4 100644 --- a/src/calibre/ebooks/fb2/input.py +++ b/src/calibre/ebooks/fb2/input.py @@ -127,7 +127,7 @@ class FB2Input(InputFormatPlugin): def extract_embedded_content(self, doc): self.binary_map = {} for elem in doc.xpath('./*'): - if 'binary' in elem.tag and elem.attrib.has_key('id'): + if elem.text and 'binary' in elem.tag and elem.attrib.has_key('id'): ct = elem.get('content-type', '') fname = elem.attrib['id'] ext = ct.rpartition('/')[-1].lower()