Small code clean ups

This commit is contained in:
2020-04-19 12:50:05 +02:00
parent 7e45b2611d
commit 4ce3c7cb32
4 changed files with 2 additions and 4 deletions

View File

@@ -85,7 +85,7 @@ def parse(data, url=None, mimetype=None, encoding=None):
for path in ruleset['path']:
if fnmatch(url, path):
parser = [x for x in parsers if x.mode == ruleset['mode']][0]
return parser(data, ruleset, encoding=encoding)
return parser(data, ruleset, encoding=encoding)
# 2) Try each and every parser