Fix #799171 (In 0.8.6 on Mac: Loading HTML pkg as ZIP file no longer picks up external style sheet from folder)

This commit is contained in:
Kovid Goyal 2011-06-18 10:00:57 -06:00
parent 5b20799629
commit 954e04a52d
2 changed files with 2 additions and 2 deletions

View File

@ -457,7 +457,7 @@ class HTMLInput(InputFormatPlugin):
href=bhref)
guessed = self.guess_type(href)[0]
media_type = guessed or self.BINARY_MIME
if 'text' in media_type:
if media_type == 'text/plain':
self.log.warn('Ignoring link to text file %r'%link_)
return None

View File

@ -1162,7 +1162,7 @@ class Manifest(object):
data = self._parse_xml(data)
elif self.media_type.lower() in OEB_STYLES:
data = self._parse_css(data)
elif 'text' in self.media_type.lower():
elif self.media_type.lower() == 'text/plain':
self.oeb.log.warn('%s contains data in TXT format'%self.href,
'converting to HTML')
data = self._parse_txt(data)