From a07f7b396b5235fe1ca9ae1ab2fd873ed94d2301 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Thu, 15 Apr 2010 06:37:23 +0530 Subject: [PATCH] Fix #5300 (png and jpg to cbr/cbz conversion issue) --- src/calibre/ebooks/metadata/archive.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/calibre/ebooks/metadata/archive.py b/src/calibre/ebooks/metadata/archive.py index fdf0ceee98..0af41c274f 100644 --- a/src/calibre/ebooks/metadata/archive.py +++ b/src/calibre/ebooks/metadata/archive.py @@ -13,7 +13,8 @@ from calibre.customize import FileTypePlugin def is_comic(list_of_names): extensions = set([x.rpartition('.')[-1].lower() for x in list_of_names]) - return len(extensions) == 1 and iter(extensions).next() in ('jpg', 'jpeg', 'png') + comic_extensions = set(['jpg', 'jpeg', 'png']) + return len(extensions - comic_extensions) == 0 class ArchiveExtract(FileTypePlugin): name = 'Archive Extract'