From 1b5a67bd49bef0b14a50c867ffeea29fc2adf96a Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Tue, 8 Mar 2011 11:55:46 -0700 Subject: [PATCH] ... --- src/calibre/library/caches.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/calibre/library/caches.py b/src/calibre/library/caches.py index d9ff43a67c..acd3b78d68 100644 --- a/src/calibre/library/caches.py +++ b/src/calibre/library/caches.py @@ -7,7 +7,7 @@ __copyright__ = '2010, Kovid Goyal ' __docformat__ = 'restructuredtext en' import re, itertools, time, traceback -from itertools import repeat, izip +from itertools import repeat from datetime import timedelta from threading import Thread @@ -788,7 +788,7 @@ class ResultCache(SearchQueryParser): # {{{ ''' if not hasattr(id_dict, 'items'): # Simple list. Make it a dict of string 'true' - self.marked_ids_dict = dict(izip(id_dict, repeat(u'true'))) + self.marked_ids_dict = dict.fromkeys(id_dict, u'true') else: self.marked_ids_dict = id_dict.copy() # Ensure that all the items in the dict are text