fix movie.parse_path, set language
This commit is contained in:
parent
340c7fb924
commit
5e989bcb19
1 changed files with 1 additions and 1 deletions
|
@ -298,7 +298,7 @@ def parse_path(path, directory_key='director'):
|
||||||
while data['partTitle'] and len(parts) and not re.search('^[a-z]{2}$', parts[0]):
|
while data['partTitle'] and len(parts) and not re.search('^[a-z]{2}$', parts[0]):
|
||||||
data['partTitle'] += '.%s' % parts.pop(0)
|
data['partTitle'] += '.%s' % parts.pop(0)
|
||||||
# language
|
# language
|
||||||
language = parts.pop(0) if len(parts) and re.search('^[a-z]{2}$', parts[0]) else None
|
data['language'] = parts.pop(0) if len(parts) and re.search('^[a-z]{2}$', parts[0]) else None
|
||||||
# extension
|
# extension
|
||||||
data['extension'] = re.sub('^mpeg$', 'mpg', extension.lower()) if extension else None
|
data['extension'] = re.sub('^mpeg$', 'mpg', extension.lower()) if extension else None
|
||||||
# type
|
# type
|
||||||
|
|
Loading…
Reference in a new issue