diff --git a/src/calibre/gui2/save.py b/src/calibre/gui2/save.py index b0d57aff68..1a6316439f 100644 --- a/src/calibre/gui2/save.py +++ b/src/calibre/gui2/save.py @@ -204,7 +204,7 @@ class Saver(QObject): def write_book(self, book_id, mi, components, fmts): base_path = os.path.join(self.root, *components) base_dir = os.path.dirname(base_path) - if self.opts.formats != 'all': + if self.opts.formats and self.opts.formats != 'all': asked_formats = {x.lower().strip() for x in self.opts.formats.split(',')} fmts = asked_formats.intersection(fmts) if not fmts: