From cbd8981ee2d455f4938ad088ef85dbdd96c27355 Mon Sep 17 00:00:00 2001 From: Ruud Date: Fri, 24 Jan 2014 16:33:10 +0100 Subject: [PATCH] Use helper --- couchpotato/core/providers/automation/letterboxd/main.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/couchpotato/core/providers/automation/letterboxd/main.py b/couchpotato/core/providers/automation/letterboxd/main.py index efd04991..dbbf53b1 100644 --- a/couchpotato/core/providers/automation/letterboxd/main.py +++ b/couchpotato/core/providers/automation/letterboxd/main.py @@ -1,9 +1,8 @@ from bs4 import BeautifulSoup -from couchpotato.core.helpers.variable import tryInt, splitString +from couchpotato.core.helpers.variable import tryInt, splitString, removeEmpty from couchpotato.core.logger import CPLog from couchpotato.core.providers.automation.base import Automation import re -from six.moves import filter log = CPLog(__name__) @@ -46,7 +45,7 @@ class Letterboxd(Automation): soup = BeautifulSoup(self.getHTMLData(self.url % username)) for movie in soup.find_all('a', attrs = {'class': 'frame'}): - match = filter(None, self.pattern.split(movie['title'])) + match = removeEmpty(self.pattern.split(movie['title'])) movies.append({'title': match[0], 'year': match[1] }) return movies