From 9f07dd5a21a912038eb207618c2a80a40ce92191 Mon Sep 17 00:00:00 2001 From: Ruud Date: Mon, 23 Jun 2014 20:46:26 +0200 Subject: [PATCH] Reindex after full scan. fix #3492 --- couchpotato/core/plugins/manage.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/couchpotato/core/plugins/manage.py b/couchpotato/core/plugins/manage.py index bec204b0..637facf9 100644 --- a/couchpotato/core/plugins/manage.py +++ b/couchpotato/core/plugins/manage.py @@ -4,6 +4,7 @@ import sys import time import traceback +from couchpotato import get_db from couchpotato.api import addApiView from couchpotato.core.event import fireEvent, addEvent, fireEventAsync from couchpotato.core.helpers.encoding import sp @@ -179,6 +180,10 @@ class Manage(Plugin): if self.shuttingDown(): break + if not self.shuttingDown(): + db = get_db() + db.reindex() + Env.prop(last_update_key, time.time()) except: log.error('Failed updating library: %s', (traceback.format_exc()))