From 9ad0ed642d1e0970972c7225bec03fe436890b76 Mon Sep 17 00:00:00 2001 From: Ruud Date: Sun, 25 Aug 2013 12:07:13 +0200 Subject: [PATCH] Don't use type yet. fix #2068 --- couchpotato/core/media/movie/library/movie/main.py | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/couchpotato/core/media/movie/library/movie/main.py b/couchpotato/core/media/movie/library/movie/main.py index 51091273..2d14b324 100644 --- a/couchpotato/core/media/movie/library/movie/main.py +++ b/couchpotato/core/media/movie/library/movie/main.py @@ -21,25 +21,20 @@ class MovieLibraryPlugin(LibraryBase): addEvent('library.update.movie_release_date', self.updateReleaseDate) def add(self, attrs = {}, update_after = True): - # movies don't yet contain these, so lets make sure to set defaults - type = attrs.get('type', 'movie') primary_provider = attrs.get('primary_provider', 'imdb') db = get_session() - l = db.query(Library).filter_by(type = type, identifier = attrs.get('identifier')).first() + l = db.query(Library).filter_by(identifier = attrs.get('identifier')).first() if not l: status = fireEvent('status.get', 'needs_update', single = True) l = Library( - type = type, - primary_provider = primary_provider, year = attrs.get('year'), identifier = attrs.get('identifier'), plot = toUnicode(attrs.get('plot')), tagline = toUnicode(attrs.get('tagline')), status_id = status.get('id'), - info = {}, - parent = None, + info = {} ) title = LibraryTitle(