diff --git a/couchpotato/core/media/movie/searcher.py b/couchpotato/core/media/movie/searcher.py index 5a8d6155..a5b1f477 100644 --- a/couchpotato/core/media/movie/searcher.py +++ b/couchpotato/core/media/movie/searcher.py @@ -54,10 +54,7 @@ class MovieSearcher(SearcherBase, MovieTypeBase): }) if self.conf('run_on_launch'): - def on_load(): - time.sleep(.1) - self.searchAll() - addEvent('app.load', on_load, priority = 1000) + addEvent('app.load', self.searchAll) def searchAllView(self, **kwargs): diff --git a/couchpotato/runner.py b/couchpotato/runner.py index 1684eddb..8c619896 100644 --- a/couchpotato/runner.py +++ b/couchpotato/runner.py @@ -10,7 +10,7 @@ import warnings import re import tarfile -from CodernityDB.database_thread_safe import ThreadSafeDatabase +from CodernityDB.database_super_thread_safe import SuperThreadSafeDatabase from argparse import ArgumentParser from cache import FileSystemCache from couchpotato import KeyHandler, LoginHandler, LogoutHandler @@ -89,7 +89,7 @@ def runCouchPotato(options, base_path, args, data_dir = None, log_dir = None, En db_path = toUnicode(os.path.join(data_dir, 'database')) # Check if database exists - db = ThreadSafeDatabase(db_path) + db = SuperThreadSafeDatabase(db_path) db_exists = db.exists() if db_exists: