From ba22e309d0143aa39427d130cb85a604a810a8a7 Mon Sep 17 00:00:00 2001 From: Charles Haley <> Date: Tue, 11 Jan 2011 17:46:08 +0000 Subject: [PATCH] Fix tags_older_than --- src/calibre/library/database2.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/calibre/library/database2.py b/src/calibre/library/database2.py index dc82825607..495cd9b685 100644 --- a/src/calibre/library/database2.py +++ b/src/calibre/library/database2.py @@ -1373,7 +1373,9 @@ class LibraryDatabase2(LibraryDatabase, SchemaUpgrade, CustomColumns): if r is not None: if (now - r[self.FIELD_MAP['timestamp']]) > delta: tags = r[self.FIELD_MAP['tags']] - if tags and tag in tags.lower(): + tags = tags.lower().split() if tags else [] + tags = [tag.strip() for tag in tags if tag.strip()] + if tag in tags: yield r[self.FIELD_MAP['id']] def get_next_series_num_for(self, series):