Properly split and strip words. fixes #137

This commit is contained in:
Ruud
2012-04-25 21:57:47 +02:00
parent 269fc66e4c
commit ac15df31d8
8 changed files with 14 additions and 14 deletions
+1 -1
View File
@@ -40,7 +40,7 @@ def nameScore(name, year):
# Contains preferred word
nzb_words = re.split('\W+', simplifyString(name))
preferred_words = Env.setting('preferred_words', section = 'searcher').split(',')
preferred_words = [x.strip() for x in Env.setting('preferred_words', section = 'searcher').split(',')]
for word in preferred_words:
if word.strip() and word.strip().lower() in nzb_words:
score = score + 100