From 1c8b5b4b4821a03c2a1d20e6ce288fdc5f89a012 Mon Sep 17 00:00:00 2001 From: j Date: Thu, 20 Oct 2022 11:09:43 +0200 Subject: [PATCH] avoid double test for h264 --- pandora/archive/extract.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/pandora/archive/extract.py b/pandora/archive/extract.py index ebfd2ae76..8731bcc13 100644 --- a/pandora/archive/extract.py +++ b/pandora/archive/extract.py @@ -57,14 +57,15 @@ def supported_formats(): stdout = stdout.decode('utf-8') stderr = stderr.decode('utf-8') version = stderr.split('\n')[0].split(' ')[2] + mp4 = 'libx264' in stdout and bool(re.compile('DEA.L. aac').findall(stdout)) return { 'version': version.split('.'), 'ogg': 'libtheora' in stdout and 'libvorbis' in stdout, 'webm': 'libvpx' in stdout and 'libvorbis' in stdout, 'vp8': 'libvpx' in stdout and 'libvorbis' in stdout, 'vp9': 'libvpx-vp9' in stdout and 'libopus' in stdout, - 'mp4': 'libx264' in stdout and bool(re.compile('DEA.L. aac').findall(stdout)), - 'h264': 'libx264' in stdout and bool(re.compile('DEA.L. aac').findall(stdout)), + 'mp4': mp4, + 'h264': mp4, } def stream(video, target, profile, info, audio_track=0, flags={}):