diff --git a/ox/file.py b/ox/file.py index 466f68d..06bbbfa 100644 --- a/ox/file.py +++ b/ox/file.py @@ -215,10 +215,16 @@ def ffprobe(filename): info['metadata'] = ffinfo['format'].get('tags', {}) for s in ffinfo['streams']: tags = s.pop('tags', {}) + language = None for t in tags: - info['metadata'][t] = tags[t] + if t == 'language': + language = tags[t] + else: + info['metadata'][t] = tags[t] if s.get('codec_type') in ('audio', 'video'): stream = {} + if language and language != 'und': + stream['language'] = language keys = [ 'codec_name', 'width',