From e3f9017e8945f14eb802e0cb6b9ed919b99435ce Mon Sep 17 00:00:00 2001 From: Charles Haley Date: Fri, 26 Sep 2014 19:02:04 +0200 Subject: [PATCH] Fix incorrect return value that causes book matching to run very slowly --- src/calibre/devices/smart_device_app/driver.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/calibre/devices/smart_device_app/driver.py b/src/calibre/devices/smart_device_app/driver.py index 0836df3807..1d8c61da0a 100644 --- a/src/calibre/devices/smart_device_app/driver.py +++ b/src/calibre/devices/smart_device_app/driver.py @@ -1553,12 +1553,12 @@ class SMART_DEVICE_APP(DeviceConfig, DevicePlugin): def _check_if_format_send_needed(self, db, id_, book): if not self.will_ask_for_update_books: - return None + return (None, False) from calibre.utils.date import parse_date, isoformat try: if not hasattr(book, '_format_mtime_'): - return None + return (None, False) ext = posixpath.splitext(book.lpath)[1][1:] fmt_metadata = db.new_api.format_metadata(id_, ext)