From 106ff4fe1140caba52cb3fd57c5c2db58d7fa3b3 Mon Sep 17 00:00:00 2001 From: Ruud Date: Sat, 1 Oct 2011 20:57:23 +0200 Subject: [PATCH] Update library handle --- couchpotato/core/plugins/library/main.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/couchpotato/core/plugins/library/main.py b/couchpotato/core/plugins/library/main.py index 1f9dd6cc..a8ad3a48 100644 --- a/couchpotato/core/plugins/library/main.py +++ b/couchpotato/core/plugins/library/main.py @@ -41,8 +41,9 @@ class LibraryPlugin(Plugin): db.commit() # Update library info - if update_after: - fireEventAsync('library.update', identifier = l.identifier, default_title = attrs.get('title', '')) + if update_after is not False: + handle = fireEventAsync if update_after is 'async' else fireEvent + handle('library.update', identifier = l.identifier, default_title = attrs.get('title', '')) return l.to_dict(self.default_dict)